You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by sp...@apache.org on 2015/02/12 14:02:01 UTC

[35/77] [partial] incubator-tinkerpop git commit: moved com/tinkerpop directories to org/apache/tinkerpop

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalHelper.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalHelper.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalHelper.java
deleted file mode 100644
index d32fd11..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalHelper.java
+++ /dev/null
@@ -1,298 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traversal.util;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.Traversal;
-import com.tinkerpop.gremlin.process.traversal.step.Reversible;
-import com.tinkerpop.gremlin.process.traversal.step.TraversalParent;
-import com.tinkerpop.gremlin.process.graph.traversal.step.map.EdgeVertexStep;
-import com.tinkerpop.gremlin.process.graph.traversal.step.map.PropertiesStep;
-import com.tinkerpop.gremlin.process.graph.traversal.step.map.VertexStep;
-import com.tinkerpop.gremlin.process.traversal.StepPosition;
-import com.tinkerpop.gremlin.process.traversal.step.EmptyStep;
-import com.tinkerpop.gremlin.process.util.BulkSet;
-import com.tinkerpop.gremlin.structure.Vertex;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Optional;
-import java.util.Set;
-import java.util.stream.Collectors;
-import java.util.stream.Stream;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public final class TraversalHelper {
-
-    private TraversalHelper() {
-    }
-
-    public static boolean isReversible(final Traversal.Admin<?, ?> traversal) {
-        return !traversal.getSteps().stream().filter(step -> !(step instanceof Reversible)).findAny().isPresent();
-    }
-
-    public static <S, E> Step<S, E> getStepByLabel(final String label, final Traversal.Admin<?, ?> traversal) {
-        return traversal.getSteps().stream()
-                .filter(step -> step.getLabel().isPresent())
-                .filter(step -> label.equals(step.getLabel().get()))
-                .findAny()
-                .orElseThrow(() -> new IllegalArgumentException("The provided step label does not exist: " + label));
-    }
-
-    public static <S, E> Step<S, E> getStepById(final String id, final Traversal.Admin<?, ?> traversal) {
-        return traversal.getSteps().stream()
-                .filter(step -> id.equals(step.getId()))
-                .findAny()
-                .orElseThrow(() -> new IllegalArgumentException("The provided step id does not exist: " + id));
-    }
-
-    public static boolean hasLabel(final String label, final Traversal.Admin<?, ?> traversal) {
-        return traversal.getSteps().stream()
-                .filter(step -> step.getLabel().isPresent())
-                .filter(step -> label.equals(step.getLabel().get()))
-                .findAny().isPresent();
-    }
-
-    public static List<String> getLabelsUpTo(final Step<?, ?> step, final Traversal.Admin<?, ?> traversal) {
-        final List<String> labels = new ArrayList<>();
-        for (final Step<?, ?> temp : traversal.getSteps()) {
-            if (temp == step) break;
-            temp.getLabel().ifPresent(labels::add);
-        }
-        return labels;
-    }
-
-    public static List<Step<?, ?>> getStepsUpTo(final Step<?, ?> step, final Traversal.Admin<?, ?> traversal) {
-        final List<Step<?, ?>> steps = new ArrayList<>();
-        for (final Step temp : traversal.getSteps()) {
-            if (temp == step) break;
-            steps.add(temp);
-        }
-        return steps;
-    }
-
-    public static boolean isLocalStarGraph(final Traversal.Admin<?, ?> traversal) {
-        char state = 'v';
-        for (final Step step : traversal.getSteps()) {
-            if (step instanceof PropertiesStep && state == 'u')
-                return false;
-            else if (step instanceof VertexStep) {
-                if (Vertex.class.isAssignableFrom(((VertexStep) step).getReturnClass())) {
-                    if (state == 'u') return false;
-                    if (state == 'v') state = 'u';
-                } else {
-                    state = 'e';
-                }
-            } else if (step instanceof EdgeVertexStep) {
-                if (state == 'e') state = 'u';
-            }
-        }
-        return true;
-    }
-
-    public static <S, E> Step<?, E> insertTraversal(final int insertIndex, final Traversal.Admin<S, E> insertTraversal, final Traversal.Admin<?, ?> traversal) {
-        if (0 == traversal.getSteps().size()) {
-            Step currentStep = EmptyStep.instance();
-            for (final Step insertStep : insertTraversal.getSteps()) {
-                currentStep = insertStep;
-                traversal.addStep(insertStep);
-            }
-            return currentStep;
-        } else {
-            Step currentStep = traversal.getSteps().get(insertIndex);
-            for (final Step insertStep : insertTraversal.getSteps()) {
-                TraversalHelper.insertAfterStep(insertStep, currentStep, traversal);
-                currentStep = insertStep;
-            }
-            return currentStep;
-        }
-    }
-
-    public static <S, E> Step<?, E> insertTraversal(final Step<?, S> previousStep, final Traversal.Admin<S, E> insertTraversal, final Traversal.Admin<?, ?> traversal) {
-        return TraversalHelper.insertTraversal(traversal.getSteps().indexOf(previousStep), insertTraversal, traversal);
-    }
-
-    public static <S, E> void insertBeforeStep(final Step<S, E> insertStep, final Step<E, ?> afterStep, final Traversal.Admin<?, ?> traversal) {
-        traversal.addStep(traversal.getSteps().indexOf(afterStep), insertStep);
-    }
-
-    public static <S, E> void insertAfterStep(final Step<S, E> insertStep, final Step<?, S> beforeStep, final Traversal.Admin<?, ?> traversal) {
-        traversal.addStep(traversal.getSteps().indexOf(beforeStep) + 1, insertStep);
-    }
-
-    public static <S, E> void replaceStep(final Step<S, E> removeStep, final Step<S, E> insertStep, final Traversal.Admin<?, ?> traversal) {
-        traversal.addStep(traversal.getSteps().indexOf(removeStep), insertStep);
-        traversal.removeStep(removeStep);
-    }
-
-    public static String makeStepString(final Step<?, ?> step, final Object... arguments) {
-        final StringBuilder builder = new StringBuilder(step.getClass().getSimpleName());
-        final List<String> strings = Stream.of(arguments)
-                .filter(o -> null != o)
-                .filter(o -> {
-                    if (o instanceof TraversalRing) {
-                        return ((TraversalRing) o).size() > 0;
-                    } else if (o instanceof Collection) {
-                        return ((Collection) o).size() > 0;
-                    } else if (o instanceof Map) {
-                        return ((Map) o).size() > 0;
-                    } else {
-                        return o.toString().length() > 0;
-                    }
-                })
-                .map(o -> {
-                    final String string = o.toString();
-                    return string.contains("$") ? "lambda" : string;
-                }).collect(Collectors.toList());
-        if (strings.size() > 0) {
-            builder.append('(');
-            builder.append(String.join(",", strings));
-            builder.append(')');
-        }
-        step.getLabel().ifPresent(label -> builder.append('@').append(label));
-        //builder.append("^").append(step.getId());
-        return builder.toString();
-    }
-
-    public static String makeTraversalString(final Traversal.Admin<?, ?> traversal) {
-        return traversal.getSteps().toString();
-    }
-
-    public static <S> List<S> getStepsOfClass(final Class<S> stepClass, final Traversal.Admin<?, ?> traversal) {
-        return (List) traversal.getSteps().stream().filter(step -> step.getClass().equals(stepClass)).collect(Collectors.toList());
-    }
-
-    public static <S> List<S> getStepsOfAssignableClass(final Class<S> stepClass, final Traversal.Admin<?, ?> traversal) {
-        return (List) traversal.getSteps().stream().filter(step -> stepClass.isAssignableFrom(step.getClass())).collect(Collectors.toList());
-    }
-
-    public static <S> Optional<S> getLastStepOfAssignableClass(final Class<S> stepClass, final Traversal.Admin<?, ?> traversal) {
-        final List<S> steps = TraversalHelper.getStepsOfAssignableClass(stepClass, traversal);
-        return steps.size() == 0 ? Optional.empty() : Optional.of(steps.get(steps.size() - 1));
-    }
-
-    public static <S> List<S> getStepsOfAssignableClassRecurssively(final Class<S> stepClass, final Traversal.Admin<?, ?> traversal) {
-        final List<S> list = new ArrayList<>();
-        for (final Step<?, ?> step : traversal.getSteps()) {
-            if (stepClass.isAssignableFrom(step.getClass()))
-                list.add((S) step);
-            if (step instanceof TraversalParent) {
-                for (final Traversal.Admin<?, ?> globalChild : ((TraversalParent) step).getGlobalChildren()) {
-                    list.addAll(TraversalHelper.getStepsOfAssignableClassRecurssively(stepClass, globalChild));
-                }
-            }
-        }
-        return list;
-    }
-
-    public static boolean hasStepOfClass(final Class stepClass, final Traversal.Admin<?, ?> traversal) {
-        for (final Step<?, ?> step : traversal.getSteps()) {
-            if (step.getClass().equals(stepClass)) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    public static boolean hasStepOfAssignableClass(final Class superClass, final Traversal.Admin<?, ?> traversal) {
-        for (final Step<?, ?> step : traversal.getSteps()) {
-            if (superClass.isAssignableFrom(step.getClass())) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    public static <S> void addToCollection(final Collection<S> collection, final S s, final long bulk) {
-        if (collection instanceof BulkSet) {
-            ((BulkSet<S>) collection).add(s, bulk);
-        } else if (collection instanceof Set) {
-            collection.add(s);
-        } else {
-            for (long i = 0; i < bulk; i++) {
-                collection.add(s);
-            }
-        }
-    }
-
-    public static <S> void addToCollectionUnrollIterator(final Collection<S> collection, final S s, final long bulk) {
-        if (s instanceof Iterator) {
-            ((Iterator<S>) s).forEachRemaining(r -> addToCollection(collection, r, bulk));
-        } else if (s instanceof Iterable) {
-            ((Iterable<S>) s).forEach(r -> addToCollection(collection, r, bulk));
-        } else {
-            addToCollection(collection, s, bulk);
-        }
-    }
-
-    /**
-     * Returns the name of <i>step</i> truncated to <i>maxLength</i>. An ellipses is appended when the name exceeds
-     * <i>maxLength</i>.
-     *
-     * @param step
-     * @param maxLength Includes the 3 "..." characters that will be appended when the length of the name exceeds
-     *                  maxLength.
-     * @return short step name.
-     */
-    public static String getShortName(final Step step, final int maxLength) {
-        final String name = step.toString();
-        if (name.length() > maxLength)
-            return name.substring(0, maxLength - 3) + "...";
-        return name;
-    }
-
-    public static void reIdSteps(final StepPosition stepPosition, final Traversal.Admin<?, ?> traversal) {
-        stepPosition.x = 0;
-        stepPosition.y = -1;
-        stepPosition.z = -1;
-        stepPosition.parentId = null;
-        Traversal.Admin<?, ?> current = traversal;
-        while (!(current instanceof EmptyTraversal)) {
-            stepPosition.y++;
-            final TraversalParent parent = current.getParent();
-            if (null == stepPosition.parentId && !(parent instanceof EmptyStep))
-                stepPosition.parentId = parent.asStep().getId();
-            if (-1 == stepPosition.z) {
-                for (int i = 0; i < parent.getGlobalChildren().size(); i++) {
-                    if (parent.getGlobalChildren().get(i) == current) {
-                        stepPosition.z = i;
-                    }
-                }
-            }
-            current = parent.asStep().getTraversal();
-        }
-        if (-1 == stepPosition.z) stepPosition.z = 0;
-        if (null == stepPosition.parentId) stepPosition.parentId = "";
-        for (final Step<?, ?> step : traversal.getSteps()) {
-            step.setId(stepPosition.nextXId());
-        }
-    }
-
-    public static Traversal.Admin<?, ?> getRootTraversal(Traversal.Admin<?, ?> traversal) {
-        while (!((traversal.getParent()) instanceof EmptyStep)) {
-            traversal = traversal.getParent().asStep().getTraversal();
-        }
-        return traversal;
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalRing.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalRing.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalRing.java
deleted file mode 100644
index 5fc87d7..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalRing.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traversal.util;
-
-import com.tinkerpop.gremlin.process.Traversal;
-import com.tinkerpop.gremlin.process.traversal.lambda.IdentityTraversal;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.List;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public final class TraversalRing<A, B> implements Serializable {
-
-    private final IdentityTraversal<A, B> identityTraversal = new IdentityTraversal<>();
-
-    private List<Traversal.Admin<A, B>> traversals = new ArrayList<>();
-    private int currentTraversal = -1;
-
-    public TraversalRing(final Traversal.Admin<A,B>... traversals) {
-        this.traversals = new ArrayList<>(Arrays.asList(traversals));
-    }
-
-    public Traversal.Admin<A, B> next() {
-        if (this.traversals.size() == 0) {
-            return this.identityTraversal;
-        } else {
-            this.currentTraversal = (this.currentTraversal + 1) % this.traversals.size();
-            return this.traversals.get(this.currentTraversal);
-        }
-    }
-
-    public boolean isEmpty() {
-        return this.traversals.isEmpty();
-    }
-
-    public void reset() {
-        this.currentTraversal = -1;
-    }
-
-    public int size() {
-        return this.traversals.size();
-    }
-
-    public void addTraversal(final Traversal.Admin<A, B> traversal) {
-        this.traversals.add(traversal);
-    }
-
-    public List<Traversal.Admin<A, B>> getTraversals() {
-        return Collections.unmodifiableList(this.traversals);
-    }
-
-    @Override
-    public String toString() {
-        return this.traversals.toString();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalUtil.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalUtil.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalUtil.java
deleted file mode 100644
index b4ccb38..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traversal/util/TraversalUtil.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traversal.util;
-
-import com.tinkerpop.gremlin.process.Traversal;
-import com.tinkerpop.gremlin.process.Traverser;
-
-import java.util.NoSuchElementException;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public final class TraversalUtil {
-
-    private TraversalUtil() {
-    }
-
-    public static final <S, E> E apply(final Traverser.Admin<S> traverser, final Traversal.Admin<S, E> traversal) {
-        final Traverser.Admin<S> split = traverser.split();
-        split.setSideEffects(traversal.getSideEffects());
-        split.setBulk(1l); // TODO: do we do this?
-        traversal.reset();
-        traversal.addStart(split);
-        try {
-            return traversal.next(); // map
-        } catch (final NoSuchElementException e) {
-            throw new IllegalArgumentException("The provided traverser does not map to a value: " + split + "->" + traversal);
-        }
-    }
-
-    public static final <S, E> boolean test(final Traverser.Admin<S> traverser, final Traversal.Admin<S, E> traversal) {
-        final Traverser.Admin<S> split = traverser.split();
-        split.setSideEffects(traversal.getSideEffects());
-        split.setBulk(1l); // TODO: do we do this?
-        traversal.reset();
-        traversal.addStart(split);
-        return traversal.hasNext(); // filter
-    }
-
-    ///////
-
-    public static final <S, E> E apply(final S start, final Traversal.Admin<S, E> traversal) {
-        traversal.reset();
-        traversal.addStart(traversal.getTraverserGenerator().generate(start, traversal.getStartStep(), 1l));
-        try {
-            return traversal.next(); // map
-        } catch (final NoSuchElementException e) {
-            throw new IllegalArgumentException("The provided start does not map to a value: " + start + "->" + traversal);
-        }
-    }
-
-    public static final <S, E> boolean test(final S start, final Traversal.Admin<S, E> traversal) {
-        traversal.reset();
-        traversal.addStart(traversal.getTraverserGenerator().generate(start, traversal.getStartStep(), 1l));
-        return traversal.hasNext(); // filter
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_Traverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_Traverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_Traverser.java
deleted file mode 100644
index e4fe7a1..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_Traverser.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-
-import com.tinkerpop.gremlin.process.Path;
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.TraversalSideEffects;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.traverser.util.AbstractPathTraverser;
-import com.tinkerpop.gremlin.process.util.path.SparsePath;
-import com.tinkerpop.gremlin.structure.Vertex;
-
-import java.util.Map;
-import java.util.Optional;
-import java.util.WeakHashMap;
-import java.util.function.UnaryOperator;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_PA_S_SE_SL_Traverser<T> extends AbstractPathTraverser<T> {
-
-    protected B_O_PA_S_SE_SL_Traverser() {
-    }
-
-    public B_O_PA_S_SE_SL_Traverser(final T t, final Step<T, ?> step) {
-        super(t, step);
-        final Optional<String> stepLabel = step.getLabel();
-        this.path = stepLabel.isPresent() ?
-                getOrCreateFromCache(this.sideEffects).extend(t, stepLabel.get()) :
-                getOrCreateFromCache(this.sideEffects).extend(t);
-    }
-
-    @Override
-    public int hashCode() {
-        return this.t.hashCode() + this.future.hashCode() + this.loops;
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return object instanceof B_O_PA_S_SE_SL_Traverser
-                && ((B_O_PA_S_SE_SL_Traverser) object).get().equals(this.t)
-                && ((B_O_PA_S_SE_SL_Traverser) object).getStepId().equals(this.getStepId())
-                && ((B_O_PA_S_SE_SL_Traverser) object).loops() == this.loops()
-                && (null == this.sack);
-    }
-
-    @Override
-    public Traverser.Admin<T> attach(final Vertex vertex) {
-        super.attach(vertex);
-        final Path newSparsePath = getOrCreateFromCache(this.sideEffects);
-        this.path.forEach((object, labels) -> newSparsePath.extend(object, labels.toArray(new String[labels.size()])));
-        this.path = newSparsePath;
-        return this;
-    }
-
-
-    @Override
-    public <R> Traverser.Admin<R> split(final R r, final Step<T, R> step) {
-        try {
-            final B_O_PA_S_SE_SL_Traverser<R> clone = (B_O_PA_S_SE_SL_Traverser<R>) super.clone();
-            clone.t = r;
-            final Optional<String> stepLabel = step.getLabel();
-            clone.path = getOrCreateFromCache(this.sideEffects); // local traversal branches are cut off from the primary path history
-            clone.path = stepLabel.isPresent() ? clone.path.clone().extend(r, stepLabel.get()) : clone.path.clone().extend(r);
-            clone.sack = null == clone.sack ? null : clone.sideEffects.getSackSplitOperator().orElse(UnaryOperator.identity()).apply(clone.sack);
-            return clone;
-        } catch (final CloneNotSupportedException e) {
-            throw new IllegalStateException(e.getMessage(), e);
-        }
-    }
-
-    //////////////////////
-
-    private static final Map<TraversalSideEffects, SparsePath> PATH_CACHE = new WeakHashMap<>();
-
-    private static SparsePath getOrCreateFromCache(final TraversalSideEffects sideEffects) {
-        SparsePath path = PATH_CACHE.get(sideEffects);
-        if (null == path) {
-            path = SparsePath.make();
-            PATH_CACHE.put(sideEffects, path);
-        }
-        return path;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_TraverserGenerator.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_TraverserGenerator.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_TraverserGenerator.java
deleted file mode 100644
index ac7b829..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_PA_S_SE_SL_TraverserGenerator.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-
-import java.util.EnumSet;
-import java.util.Set;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_PA_S_SE_SL_TraverserGenerator implements TraverserGenerator {
-
-    private static final B_O_PA_S_SE_SL_TraverserGenerator INSTANCE = new B_O_PA_S_SE_SL_TraverserGenerator();
-
-    private static final Set<TraverserRequirement> REQUIREMENTS = EnumSet.of(
-            TraverserRequirement.OBJECT,
-            TraverserRequirement.BULK,
-            TraverserRequirement.SINGLE_LOOP,
-            TraverserRequirement.PATH_ACCESS,
-            TraverserRequirement.SACK,
-            TraverserRequirement.SIDE_EFFECTS);
-
-
-    private B_O_PA_S_SE_SL_TraverserGenerator() {
-    }
-
-    @Override
-    public <S> Traverser.Admin<S> generate(final S start, final Step<S, ?> startStep, final long initialBulk) {
-        final B_O_PA_S_SE_SL_Traverser<S> traverser = new B_O_PA_S_SE_SL_Traverser<>(start, startStep);
-        traverser.setBulk(initialBulk);
-        return traverser;
-    }
-
-    @Override
-    public Set<TraverserRequirement> getProvidedRequirements() {
-        return REQUIREMENTS;
-    }
-
-    public static B_O_PA_S_SE_SL_TraverserGenerator instance() {
-        return INSTANCE;
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_Traverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_Traverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_Traverser.java
deleted file mode 100644
index a9b20cd..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_Traverser.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.traverser.util.AbstractPathTraverser;
-import com.tinkerpop.gremlin.process.util.path.ImmutablePath;
-
-import java.util.Optional;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_P_PA_S_SE_SL_Traverser<T> extends AbstractPathTraverser<T> {
-
-    protected B_O_P_PA_S_SE_SL_Traverser() {
-    }
-
-    public B_O_P_PA_S_SE_SL_Traverser(final T t, final Step<T, ?> step) {
-        super(t, step);
-        final Optional<String> stepLabel = step.getLabel();
-        this.path = stepLabel.isPresent() ?
-                ImmutablePath.make().extend(t, stepLabel.get()) :
-                ImmutablePath.make().extend(t);
-    }
-
-    @Override
-    public int hashCode() {
-        return super.hashCode() + this.path.hashCode();
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return (object instanceof B_O_P_PA_S_SE_SL_Traverser)
-                && ((B_O_P_PA_S_SE_SL_Traverser) object).path().equals(this.path) // TODO: path equality
-                && ((B_O_P_PA_S_SE_SL_Traverser) object).get().equals(this.t)
-                && ((B_O_P_PA_S_SE_SL_Traverser) object).getStepId().equals(this.getStepId())
-                && ((B_O_P_PA_S_SE_SL_Traverser) object).loops() == this.loops()
-                && (null == this.sack);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_TraverserGenerator.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_TraverserGenerator.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_TraverserGenerator.java
deleted file mode 100644
index b1deb47..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_P_PA_S_SE_SL_TraverserGenerator.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-
-import java.util.EnumSet;
-import java.util.Set;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_P_PA_S_SE_SL_TraverserGenerator implements TraverserGenerator {
-
-    private static final B_O_P_PA_S_SE_SL_TraverserGenerator INSTANCE = new B_O_P_PA_S_SE_SL_TraverserGenerator();
-    private static final Set<TraverserRequirement> REQUIREMENTS = EnumSet.of(
-            TraverserRequirement.OBJECT,
-            TraverserRequirement.BULK,
-            TraverserRequirement.SINGLE_LOOP,
-            TraverserRequirement.PATH_ACCESS,
-            TraverserRequirement.PATH,
-            TraverserRequirement.SACK,
-            TraverserRequirement.SIDE_EFFECTS);
-
-    private B_O_P_PA_S_SE_SL_TraverserGenerator() {
-    }
-
-    @Override
-    public <S> Traverser.Admin<S> generate(final S start, final Step<S, ?> startStep, final long initialBulk) {
-        final B_O_P_PA_S_SE_SL_Traverser<S> traverser = new B_O_P_PA_S_SE_SL_Traverser<>(start, startStep);
-        traverser.setBulk(initialBulk);
-        return traverser;
-    }
-
-    @Override
-    public Set<TraverserRequirement> getProvidedRequirements() {
-        return REQUIREMENTS;
-    }
-
-    public static B_O_P_PA_S_SE_SL_TraverserGenerator instance() {
-        return INSTANCE;
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_Traverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_Traverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_Traverser.java
deleted file mode 100644
index 7b7e25d..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_Traverser.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Traverser;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_Traverser<T> extends O_Traverser<T> {
-
-    protected long bulk = 1l;
-    protected String future = HALT;
-
-    protected B_O_Traverser() {
-    }
-
-    public B_O_Traverser(final T t, final long initialBulk) {
-        super(t);
-        this.bulk = initialBulk;
-    }
-
-    @Override
-    public void setBulk(final long count) {
-        this.bulk = count;
-    }
-
-    @Override
-    public long bulk() {
-        return this.bulk;
-    }
-
-    @Override
-    public void merge(final Traverser.Admin<?> other) {
-        this.bulk = this.bulk + other.bulk();
-    }
-
-    @Override
-    public String getStepId() {
-        return this.future;
-    }
-
-    @Override
-    public void setStepId(final String stepId) {
-        this.future = stepId;
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return object instanceof B_O_Traverser &&
-                ((B_O_Traverser) object).t.equals(this.t) &&
-                ((B_O_Traverser) object).future.equals(this.future);
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_TraverserGenerator.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_TraverserGenerator.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_TraverserGenerator.java
deleted file mode 100644
index d940ae4..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/B_O_TraverserGenerator.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-
-import java.util.EnumSet;
-import java.util.Set;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class B_O_TraverserGenerator implements TraverserGenerator {
-
-    private static final Set<TraverserRequirement> REQUIREMENTS = EnumSet.of(
-            TraverserRequirement.OBJECT,
-            TraverserRequirement.BULK);
-
-    private static final B_O_TraverserGenerator INSTANCE = new B_O_TraverserGenerator();
-
-    private B_O_TraverserGenerator() {
-    }
-
-    @Override
-    public <S> Traverser.Admin<S> generate(final S start, final Step<S, ?> startStep, final long initialBulk) {
-        return new B_O_Traverser<>(start, initialBulk);
-    }
-
-    @Override
-    public Set<TraverserRequirement> getProvidedRequirements() {
-        return REQUIREMENTS;
-    }
-
-    public static B_O_TraverserGenerator instance() {
-        return INSTANCE;
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_Traverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_Traverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_Traverser.java
deleted file mode 100644
index 8cc65d7..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_Traverser.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.traverser.util.AbstractTraverser;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class O_Traverser<T> extends AbstractTraverser<T> {
-
-    protected O_Traverser() {
-    }
-
-    public O_Traverser(final T t) {
-        super(t);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_TraverserGenerator.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_TraverserGenerator.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_TraverserGenerator.java
deleted file mode 100644
index cec31b5..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/O_TraverserGenerator.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-
-import java.util.Collections;
-import java.util.Set;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class O_TraverserGenerator implements TraverserGenerator {
-
-    private static final Set<TraverserRequirement> REQUIREMENTS = Collections.singleton(TraverserRequirement.OBJECT);
-    private static final O_TraverserGenerator INSTANCE = new O_TraverserGenerator();
-
-    private O_TraverserGenerator() {
-    }
-
-    @Override
-    public <S> Traverser.Admin<S> generate(final S start, final Step<S, ?> startStep, final long initialBulk) {
-        return new O_Traverser<>(start);
-    }
-
-    @Override
-    public Set<TraverserRequirement> getProvidedRequirements() {
-        return REQUIREMENTS;
-    }
-
-    public static O_TraverserGenerator instance() {
-        return INSTANCE;
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserGeneratorFactory.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserGeneratorFactory.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserGeneratorFactory.java
deleted file mode 100644
index aa6225c..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserGeneratorFactory.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-import com.tinkerpop.gremlin.process.Traversal;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-
-import java.io.Serializable;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public interface TraverserGeneratorFactory extends Serializable {
-
-    public TraverserGenerator getTraverserGenerator(final Traversal.Admin<?, ?> traversal);
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserRequirement.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserRequirement.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserRequirement.java
deleted file mode 100644
index 6648f9b..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/TraverserRequirement.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser;
-
-/**
- * A {@link TraverserRequirement} is a list of requirements that a {@link com.tinkerpop.gremlin.process.Traversal} requires of a {@link com.tinkerpop.gremlin.process.Traverser}.
- * The less requirements, the simpler the traverser can be (both in terms of space and time constraints).
- * Every {@link com.tinkerpop.gremlin.process.Step} provides its specific requirements via {@link com.tinkerpop.gremlin.process.Step#getRequirements()}.
- *
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public enum TraverserRequirement {
-
-    OBJECT,
-    BULK,
-    SINGLE_LOOP,
-    NESTED_LOOP,
-    PATH,
-    PATH_ACCESS,
-    SACK,
-    SIDE_EFFECTS,
-    // NESTED_TRAVERSALS
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractPathTraverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractPathTraverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractPathTraverser.java
deleted file mode 100644
index 0b16643..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractPathTraverser.java
+++ /dev/null
@@ -1,208 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser.util;
-
-import com.tinkerpop.gremlin.process.Path;
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.TraversalSideEffects;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.structure.Vertex;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedElement;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedFactory;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedProperty;
-
-import java.util.Optional;
-import java.util.function.UnaryOperator;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public abstract class AbstractPathTraverser<T> implements Traverser<T>, Traverser.Admin<T> {
-
-    protected T t;
-    protected Object sack = null;
-    protected String future = HALT;
-    protected short loops = 0;  // an optimization hack to use a short internally to save bits :)
-    protected transient TraversalSideEffects sideEffects;
-    protected long bulk = 1l;
-    protected Path path;
-
-    protected AbstractPathTraverser() {
-
-    }
-
-    public AbstractPathTraverser(final T t, final Step<T, ?> step) {
-        this.t = t;
-        this.sideEffects = step.getTraversal().getSideEffects();
-        this.sideEffects.getSackInitialValue().ifPresent(supplier -> this.sack = supplier.get());
-    }
-
-    /////////////////
-
-    @Override
-    public T get() {
-        return this.t;
-    }
-
-    @Override
-    public void set(final T t) {
-        this.t = t;
-    }
-
-    /////////////////
-
-    @Override
-    public Path path() {
-        return this.path;
-    }
-
-    /////////////////
-
-    @Override
-    public <S> S sack() {
-        return (S) this.sack;
-    }
-
-    @Override
-    public <S> void sack(final S object) {
-        this.sack = object;
-    }
-
-    /////////////////
-
-    @Override
-    public void setBulk(final long count) {
-        this.bulk = count;
-    }
-
-    @Override
-    public long bulk() {
-        return this.bulk;
-    }
-
-    /////////////////
-
-    @Override
-    public int loops() {
-        return this.loops;
-    }
-
-    @Override
-    public void incrLoops(final String stepLabel) {
-        this.loops++;
-    }
-
-    @Override
-    public void resetLoops() {
-        this.loops = 0;
-    }
-
-    /////////////////
-
-    @Override
-    public String getStepId() {
-        return this.future;
-    }
-
-    @Override
-    public void setStepId(final String stepId) {
-        this.future = stepId;
-    }
-
-    /////////////////
-
-    @Override
-    public TraversalSideEffects getSideEffects() {
-        return this.sideEffects;
-    }
-
-
-    @Override
-    public void setSideEffects(final TraversalSideEffects sideEffects) {
-        this.sideEffects = sideEffects;
-    }
-
-    /////////////////
-
-    @Override
-    public Traverser.Admin<T> detach() {
-        this.t = DetachedFactory.detach(this.t, false);
-        this.path = DetachedFactory.detach(this.path, true);
-        return this;
-    }
-
-    @Override
-    public Traverser.Admin<T> attach(final Vertex vertex) {
-        if (this.t instanceof DetachedElement)
-            this.t = (T) ((DetachedElement) this.t).attach(vertex);
-        else if (this.t instanceof DetachedProperty)
-            this.t = (T) ((DetachedProperty) this.t).attach(vertex);
-        // you do not want to attach a path because it will reference graph objects not at the current vertex
-        return this;
-    }
-
-    /////////////////
-
-    @Override
-    public void merge(final Traverser.Admin<?> other) {
-        this.bulk = this.bulk + other.bulk();
-    }
-
-    @Override
-    public <R> Traverser.Admin<R> split(final R r, final Step<T, R> step) {
-        try {
-            final AbstractPathTraverser<R> clone = (AbstractPathTraverser<R>) super.clone();
-            clone.t = r;
-            final Optional<String> stepLabel = step.getLabel();
-            clone.path = stepLabel.isPresent() ? clone.path.clone().extend(r, stepLabel.get()) : clone.path.clone().extend(r);
-            clone.sack = null == clone.sack ? null : clone.sideEffects.getSackSplitOperator().orElse(UnaryOperator.identity()).apply(clone.sack);
-            return clone;
-        } catch (final CloneNotSupportedException e) {
-            throw new IllegalStateException(e.getMessage(), e);
-        }
-    }
-
-    @Override
-    public Traverser.Admin<T> split() {
-        try {
-            final AbstractPathTraverser<T> clone = (AbstractPathTraverser<T>) super.clone();
-            clone.sack = null == clone.sack ? null : clone.sideEffects.getSackSplitOperator().orElse(UnaryOperator.identity()).apply(clone.sack);
-            return clone;
-        } catch (final CloneNotSupportedException e) {
-            throw new IllegalStateException(e.getMessage(), e);
-        }
-    }
-
-    /////////////////
-
-    @Override
-    public AbstractPathTraverser<T> clone() throws CloneNotSupportedException {
-        return (AbstractPathTraverser<T>) super.clone();
-    }
-
-    @Override
-    public int hashCode() {
-        return this.t.hashCode() + this.future.hashCode() + this.loops;
-    }
-
-    @Override
-    public String toString() {
-        return this.t.toString();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractTraverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractTraverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractTraverser.java
deleted file mode 100644
index b505ad6..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/AbstractTraverser.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser.util;
-
-import com.tinkerpop.gremlin.process.Path;
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.TraversalSideEffects;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.util.path.EmptyPath;
-import com.tinkerpop.gremlin.process.traversal.util.EmptyTraversalSideEffects;
-import com.tinkerpop.gremlin.structure.Vertex;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedElement;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedFactory;
-import com.tinkerpop.gremlin.structure.util.detached.DetachedProperty;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public abstract class AbstractTraverser<T> implements Traverser<T>, Traverser.Admin<T> {
-
-    protected T t;
-
-    protected AbstractTraverser() {
-
-    }
-
-    public AbstractTraverser(final T t) {
-        this.t = t;
-    }
-
-    /////////////
-
-    @Override
-    public void merge(final Admin<?> other) {
-        throw new UnsupportedOperationException("This traverser does not support merging: " + this.getClass().getCanonicalName());
-    }
-
-    @Override
-    public <R> Admin<R> split(final R r, final Step<T, R> step) {
-        try {
-            final AbstractTraverser<R> clone = (AbstractTraverser<R>) super.clone();
-            clone.t = r;
-            return clone;
-        } catch (final CloneNotSupportedException e) {
-            throw new IllegalStateException(e.getMessage(), e);
-        }
-    }
-
-    @Override
-    public Admin<T> split() {
-        try {
-            return (AbstractTraverser<T>) super.clone();
-        } catch (final CloneNotSupportedException e) {
-            throw new IllegalStateException(e.getMessage(), e);
-        }
-    }
-
-    @Override
-    public void set(final T t) {
-        this.t = t;
-    }
-
-    @Override
-    public void incrLoops(final String stepLabel) {
-
-    }
-
-    @Override
-    public void resetLoops() {
-
-    }
-
-    @Override
-    public String getStepId() {
-        throw new UnsupportedOperationException("This traverser does not support futures: " + this.getClass().getCanonicalName());
-    }
-
-    @Override
-    public void setStepId(final String stepId) {
-
-    }
-
-    @Override
-    public void setBulk(final long count) {
-
-    }
-
-    @Override
-    public Admin<T> detach() {
-        this.t = DetachedFactory.detach(this.t, false);
-        return this;
-    }
-
-    @Override
-    public Admin<T> attach(final Vertex hostVertex) {
-        if (this.t instanceof DetachedElement)
-            this.t = (T) ((DetachedElement) this.t).attach(hostVertex);
-        else if (this.t instanceof DetachedProperty)
-            this.t = (T) ((DetachedProperty) this.t).attach(hostVertex);
-        // you do not want to attach a path because it will reference graph objects not at the current vertex
-        return this;
-    }
-
-    @Override
-    public void setSideEffects(final TraversalSideEffects sideEffects) {
-
-    }
-
-    @Override
-    public TraversalSideEffects getSideEffects() {
-        return EmptyTraversalSideEffects.instance();
-        //throw new UnsupportedOperationException("This traverser does not support sideEffects: " + this.getClass().getCanonicalName());
-    }
-
-    @Override
-    public T get() {
-        return this.t;
-    }
-
-    @Override
-    public <S> S sack() {
-        throw new UnsupportedOperationException("This traverser does not support sacks: " + this.getClass().getCanonicalName());
-    }
-
-    @Override
-    public <S> void sack(final S object) {
-
-    }
-
-    @Override
-    public Path path() {
-        return EmptyPath.instance();
-    }
-
-    @Override
-    public int loops() {
-        throw new UnsupportedOperationException("This traverser does not support loops: " + this.getClass().getCanonicalName());
-    }
-
-    @Override
-    public long bulk() {
-        return 1l;
-    }
-
-    @Override
-    public AbstractTraverser<T> clone() throws CloneNotSupportedException {
-        return (AbstractTraverser<T>) super.clone();
-    }
-
-    ///////////
-
-    @Override
-    public int hashCode() {
-        return this.t.hashCode();
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return object instanceof AbstractTraverser && ((AbstractTraverser) object).get().equals(this.t);
-    }
-
-    @Override
-    public String toString() {
-        return this.t.toString();
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/DefaultTraverserGeneratorFactory.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/DefaultTraverserGeneratorFactory.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/DefaultTraverserGeneratorFactory.java
deleted file mode 100644
index 8f1752b..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/DefaultTraverserGeneratorFactory.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser.util;
-
-import com.tinkerpop.gremlin.process.Traversal;
-import com.tinkerpop.gremlin.process.TraverserGenerator;
-import com.tinkerpop.gremlin.process.traverser.B_O_PA_S_SE_SL_TraverserGenerator;
-import com.tinkerpop.gremlin.process.traverser.B_O_P_PA_S_SE_SL_TraverserGenerator;
-import com.tinkerpop.gremlin.process.traverser.B_O_TraverserGenerator;
-import com.tinkerpop.gremlin.process.traverser.O_TraverserGenerator;
-import com.tinkerpop.gremlin.process.traverser.TraverserGeneratorFactory;
-import com.tinkerpop.gremlin.process.traverser.TraverserRequirement;
-
-import java.util.Set;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class DefaultTraverserGeneratorFactory implements TraverserGeneratorFactory {
-
-    private static DefaultTraverserGeneratorFactory INSTANCE = new DefaultTraverserGeneratorFactory();
-
-    public static DefaultTraverserGeneratorFactory instance() {
-        return INSTANCE;
-    }
-
-    private DefaultTraverserGeneratorFactory() {
-    }
-
-    @Override
-    public TraverserGenerator getTraverserGenerator(final Traversal.Admin<?,?> traversal) {
-        final Set<TraverserRequirement> requirements = traversal.getTraverserRequirements();
-
-        if (O_TraverserGenerator.instance().getProvidedRequirements().containsAll(requirements))
-            return O_TraverserGenerator.instance();
-
-        if (B_O_TraverserGenerator.instance().getProvidedRequirements().containsAll(requirements))
-            return B_O_TraverserGenerator.instance();
-
-        if (B_O_PA_S_SE_SL_TraverserGenerator.instance().getProvidedRequirements().containsAll(requirements))
-            return B_O_PA_S_SE_SL_TraverserGenerator.instance();
-
-        if (B_O_P_PA_S_SE_SL_TraverserGenerator.instance().getProvidedRequirements().containsAll(requirements))
-            return B_O_P_PA_S_SE_SL_TraverserGenerator.instance();
-
-        throw new IllegalStateException("The provided traverser generator factory does not support the requirements of the traversal: " + this.getClass().getCanonicalName() + requirements);
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/EmptyTraverser.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/EmptyTraverser.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/EmptyTraverser.java
deleted file mode 100644
index 8ce146e..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/traverser/util/EmptyTraverser.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.traverser.util;
-
-import com.tinkerpop.gremlin.process.Path;
-import com.tinkerpop.gremlin.process.Step;
-import com.tinkerpop.gremlin.process.TraversalSideEffects;
-import com.tinkerpop.gremlin.process.Traverser;
-import com.tinkerpop.gremlin.process.util.path.EmptyPath;
-import com.tinkerpop.gremlin.structure.Vertex;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public final class EmptyTraverser<T> implements Traverser<T>, Traverser.Admin<T> {
-
-    private static final EmptyTraverser INSTANCE = new EmptyTraverser();
-
-    public static <R> EmptyTraverser<R> instance() {
-        return INSTANCE;
-    }
-
-    private EmptyTraverser() {
-
-    }
-
-    @Override
-    public void set(final T t) {
-
-    }
-
-    @Override
-    public void incrLoops(final String stepLabel) {
-
-    }
-
-    @Override
-    public void resetLoops() {
-
-    }
-
-    @Override
-    public String getStepId() {
-        return HALT;
-    }
-
-    @Override
-    public void setStepId(final String stepId) {
-
-    }
-
-    @Override
-    public void setBulk(long count) {
-
-    }
-
-    @Override
-    public <R> Admin<R> split(final R r, final Step<T, R> step) {
-        return INSTANCE;
-    }
-
-    @Override
-    public Admin<T> split() {
-        return this;
-    }
-
-    @Override
-    public Admin<T> detach() {
-        return this;
-    }
-
-    @Override
-    public Admin<T> attach(final Vertex hostVertex) {
-        return this;
-    }
-
-    @Override
-    public void setSideEffects(final TraversalSideEffects sideEffects) {
-
-    }
-
-    @Override
-    public T get() {
-        return null;
-    }
-
-    @Override
-    public <S> S sack() {
-        return null;
-    }
-
-    @Override
-    public <S> void sack(final S object) {
-
-    }
-
-    @Override
-    public void merge(final Traverser.Admin<?> other) {
-
-    }
-
-    @Override
-    public Path path() {
-        return EmptyPath.instance();
-    }
-
-    @Override
-    public int loops() {
-        return 0;
-    }
-
-    @Override
-    public long bulk() {
-        return 0l;
-    }
-
-    @Override
-    public TraversalSideEffects getSideEffects() {
-        return null;
-    }
-
-    @Override
-    public int hashCode() {
-        return 380473707;
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return object instanceof EmptyTraverser;
-    }
-
-    @Override
-    public EmptyTraverser<T> clone() throws CloneNotSupportedException {
-        return this;
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/BulkSet.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/BulkSet.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/BulkSet.java
deleted file mode 100644
index 3691ecf..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/BulkSet.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.util;
-
-import java.io.Serializable;
-import java.util.AbstractSet;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Objects;
-import java.util.Set;
-import java.util.Spliterator;
-import java.util.function.BiConsumer;
-import java.util.stream.Collectors;
-
-/**
- * BulkSet is a weighted set (i.e. a multi-set). Objects are added along with a bulk counter the denotes how many times the object was added to the set.
- * Given that count-based compression (vs. enumeration) can yield large sets, methods exist that are long-based (2^64).
- *
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class BulkSet<S> extends AbstractSet<S> implements Set<S>, Serializable {
-    private final Map<S, Long> map = new LinkedHashMap<>();
-
-    @Override
-    public int size() {
-        return (int) this.longSize();
-    }
-
-    public int uniqueSize() {
-        return this.map.size();
-    }
-
-    public long longSize() {
-        return this.map.values().stream().collect(Collectors.summingLong(Long::longValue));
-    }
-
-    @Override
-    public boolean isEmpty() {
-        return this.map.isEmpty();
-    }
-
-    @Override
-    public boolean contains(final Object s) {
-        return this.map.containsKey(s);
-    }
-
-    @Override
-    public boolean add(final S s) {
-        return this.add(s, 1l);
-    }
-
-    @Override
-    public boolean addAll(final Collection<? extends S> collection) {
-        if (collection instanceof BulkSet) {
-            ((BulkSet<S>) collection).map.forEach(this::add);
-        } else {
-            collection.iterator().forEachRemaining(this::add);
-        }
-        return true;
-    }
-
-    public void forEach(final BiConsumer<S, Long> consumer) {
-        this.map.forEach(consumer);
-    }
-
-    public boolean add(final S s, final long bulk) {
-        final Long current = this.map.get(s);
-        if (current != null) {
-            this.map.put(s, current + bulk);
-            return false;
-        } else {
-            this.map.put(s, bulk);
-            return true;
-        }
-    }
-
-    public long get(final S s) {
-        final Long bulk = this.map.get(s);
-        return null == bulk ? 0 : bulk;
-    }
-
-    /*public void set(final S s, final long bulk) {
-        this.map.remove(s);
-        this.map.put(s, bulk);
-    }*/
-
-    @Override
-    public boolean remove(final Object s) {
-        return this.map.remove(s) != null;
-    }
-
-    @Override
-    public void clear() {
-        this.map.clear();
-    }
-
-    @Override
-    public Spliterator<S> spliterator() {
-        return this.toList().spliterator();
-    }
-
-    @Override
-    public boolean removeAll(final Collection<?> collection) {
-        Objects.requireNonNull(collection);
-        boolean modified = false;
-        for (final Object object : collection) {
-            if (null != this.map.remove(object))
-                modified = true;
-        }
-        return modified;
-    }
-
-    @Override
-    public int hashCode() {
-        return this.map.hashCode();
-    }
-
-    @Override
-    public boolean equals(final Object object) {
-        return this.map.equals(object);
-    }
-
-    @Override
-    public String toString() {
-        return this.map.toString();
-    }
-
-    private List<S> toList() {
-        final List<S> list = new ArrayList<>();
-        this.map.forEach((k, v) -> {
-            for (long i = 0; i < v; i++) {
-                list.add(k);
-            }
-        });
-        return list;
-    }
-
-    @Override
-    public Iterator<S> iterator() {
-        return new Iterator<S>() {
-            final Iterator<Map.Entry<S, Long>> entryIterator = map.entrySet().iterator();
-            S lastObject = null;
-            long lastCount = 0l;
-
-            public boolean hasNext() {
-                return this.lastCount > 0l || this.entryIterator.hasNext();
-            }
-
-            @Override
-            public S next() {
-                if (this.lastCount > 0l) {
-                    this.lastCount--;
-                    return this.lastObject;
-                }
-                final Map.Entry<S, Long> entry = entryIterator.next();
-                if (entry.getValue() == 1) {
-                    return entry.getKey();
-                } else {
-                    this.lastObject = entry.getKey();
-                    this.lastCount = entry.getValue() - 1;
-                    return this.lastObject;
-                }
-            }
-        };
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/MapHelper.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/MapHelper.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/MapHelper.java
deleted file mode 100644
index 04ed533..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/MapHelper.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.util;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public final class MapHelper {
-
-    private MapHelper() {
-    }
-
-    public static <T> void incr(final Map<T, Long> map, final T key, final Long value) {
-        map.put(key, value + map.getOrDefault(key, 0l));
-    }
-
-    public static <T> void incr(final Map<T, Double> map, final T key, final Double value) {
-        map.put(key, value + map.getOrDefault(key, 0.0d));
-    }
-
-    public static <T, U> void incr(final Map<T, List<U>> map, final T key, final U value) {
-        map.compute(key, (k, v) -> {
-            if (null == v) v = new ArrayList<>();
-            v.add(value);
-            return v;
-        });
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/TraverserSet.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/TraverserSet.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/TraverserSet.java
deleted file mode 100644
index 6227cff..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/TraverserSet.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.util;
-
-import com.tinkerpop.gremlin.process.Traverser;
-
-import java.io.Serializable;
-import java.util.AbstractSet;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Queue;
-import java.util.Set;
-import java.util.Spliterator;
-
-/**
- * @author Marko A. Rodriguez (http://markorodriguez.com)
- */
-public class TraverserSet<S> extends AbstractSet<Traverser.Admin<S>> implements Set<Traverser.Admin<S>>, Queue<Traverser.Admin<S>>, Serializable {
-
-    private final Map<Traverser.Admin<S>, Traverser.Admin<S>> map = new LinkedHashMap<>();
-
-    public TraverserSet() {
-
-    }
-
-    public TraverserSet(final Traverser.Admin<S> traverser) {
-        this.map.put(traverser, traverser);
-    }
-
-    @Override
-    public Iterator<Traverser.Admin<S>> iterator() {
-        return this.map.values().iterator();
-    }
-
-    public Traverser.Admin<S> get(final Traverser.Admin<S> traverser) {
-        return this.map.get(traverser);
-    }
-
-    @Override
-    public int size() {
-        return this.map.size();
-    }
-
-    public long bulkSize() {
-        return this.map.values().stream().map(Traverser::bulk).reduce(0l, (a, b) -> a + b);
-    }
-
-    @Override
-    public boolean isEmpty() {
-        return this.map.isEmpty();
-    }
-
-    @Override
-    public boolean contains(final Object traverser) {
-        return this.map.containsKey(traverser);
-    }
-
-    @Override
-    public boolean add(final Traverser.Admin<S> traverser) {
-        final Traverser.Admin<S> existing = this.map.get(traverser);
-        if (null == existing) {
-            this.map.put(traverser, traverser);
-            return true;
-        } else {
-            existing.merge(traverser);
-            return false;
-        }
-    }
-
-    @Override
-    public boolean offer(final Traverser.Admin<S> traverser) {
-        return this.add(traverser);
-    }
-
-    @Override
-    public Traverser.Admin<S> remove() {  // pop, exception if empty
-        return this.map.remove(this.map.values().iterator().next());
-    }
-
-    @Override
-    public Traverser.Admin<S> poll() {  // pop, null if empty
-        return this.map.isEmpty() ? null : this.remove();
-    }
-
-    @Override
-    public Traverser.Admin<S> element() { // peek, exception if empty
-        return this.iterator().next();
-    }
-
-    @Override
-    public Traverser.Admin<S> peek() { // peek, null if empty
-        return this.map.isEmpty() ? null : this.iterator().next();
-    }
-
-    @Override
-    public boolean remove(final Object traverser) {
-        return this.map.remove(traverser) != null;
-    }
-
-    @Override
-    public void clear() {
-        this.map.clear();
-    }
-
-    @Override
-    public Spliterator<Traverser.Admin<S>> spliterator() {
-        return this.map.values().spliterator();
-    }
-
-    @Override
-    public String toString() {
-        return this.map.values().toString();
-    }
-
-    public void sort(final Comparator<Traverser<S>> comparator) {
-        final List<Traverser.Admin<S>> list = new ArrayList<>(this.map.values());
-        Collections.sort(list, comparator);
-        this.map.clear();
-        list.forEach(traverser -> this.map.put(traverser, traverser));
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/ImmutableMetrics.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/ImmutableMetrics.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/ImmutableMetrics.java
deleted file mode 100644
index f4db632..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/ImmutableMetrics.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.util.metric;
-
-import java.io.Serializable;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.concurrent.TimeUnit;
-
-/**
- * @author Bob Briody (http://bobbriody.com)
- */
-public class ImmutableMetrics implements Metrics, Serializable {
-
-    static final TimeUnit SOURCE_UNIT = TimeUnit.NANOSECONDS;
-
-    protected String id;
-    protected String name;
-    protected long count;
-    protected long durationNs = 0l;
-    protected double percentDuration = -1;
-    protected final Map<String, String> annotations = new HashMap<>();
-    protected final Map<String, ImmutableMetrics> nested = new HashMap<>();
-
-    protected ImmutableMetrics() {
-    }
-
-    @Override
-    public long getDuration(TimeUnit unit) {
-        return unit.convert(this.durationNs, SOURCE_UNIT);
-    }
-
-    @Override
-    public long getCount() {
-        return count;
-    }
-
-    @Override
-    public String getName() {
-        return name;
-    }
-
-    public String getId() {
-        return id;
-    }
-
-    @Override
-    public double getPercentDuration() {
-        return this.percentDuration;
-    }
-
-    @Override
-    public Collection<ImmutableMetrics> getNested() {
-        return nested.values();
-    }
-
-    @Override
-    public ImmutableMetrics getNested(String metricsId) {
-        return nested.get(metricsId);
-    }
-
-    @Override
-    public Map<String, String> getAnnotations() {
-        return annotations;
-    }
-
-    @Override
-    public String toString() {
-        return "Metrics{" +
-                "durationNs=" + durationNs +
-                ", count=" + count +
-                ", name='" + name + '\'' +
-                ", id='" + id + '\'' +
-                '}';
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1545201f/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/Metrics.java
----------------------------------------------------------------------
diff --git a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/Metrics.java b/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/Metrics.java
deleted file mode 100644
index c114b79..0000000
--- a/gremlin-core/src/main/java/com/tinkerpop/gremlin/process/util/metric/Metrics.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tinkerpop.gremlin.process.util.metric;
-
-import java.util.Collection;
-import java.util.Map;
-import java.util.concurrent.TimeUnit;
-
-/**
- * Holds metrics data; typically for .profile()-step analysis. Metrics may be nested. Nesting enables the ability to
- * capture explicit metrics for multiple distinct operations. Annotations are used to store miscellaneous notes that
- * might be useful to a developer when examining results, such as index coverage for Steps in a Traversal.
- *
- * @author Bob Briody (http://bobbriody.com)
- */
-public interface Metrics {
-
-    /**
-     * Get the duration of execution time taken.
-     *
-     * @param units
-     * @return
-     */
-    public long getDuration(TimeUnit units);
-
-    /**
-     * The number of items operated upon. For a Travseral Step, this will be the number of Traversers (which may be less
-     * than the number of Elements when Elements are bulked).
-     *
-     * @return Number of items operated upon.
-     */
-    public long getCount();
-
-    /**
-     * Name of this Metrics.
-     *
-     * @return name of this Metrics.
-     */
-    public String getName();
-
-    /**
-     * Id of this Metrics.
-     *
-     * @return id of this Metrics.
-     */
-    public String getId();
-
-    /**
-     * If this Metrics object has multiple peer Metrics then this value will represent the percentage of the total
-     * duration taken by this Metrics object.
-     *
-     * @return
-     */
-    public double getPercentDuration();
-
-    /**
-     * Get the nested Metrics objects.
-     *
-     * @return the nested Metrics objects.
-     */
-    public Collection<? extends Metrics> getNested();
-
-    /**
-     * Get a nested Metrics object by Id.
-     *
-     * @param metricsId
-     * @return a nested Metrics object.
-     */
-    Metrics getNested(String metricsId);
-
-    /**
-     * Obtain the annotations for this Metrics.
-     *
-     * @return the annotations for this Metrics. Modifications to the returned object are persisted in the original.
-     */
-    public Map<String, String> getAnnotations();
-}