Tabnine Logo
GremlinPipeline.as
Code IndexAdd Tabnine to your IDE (free)

How to use
as
method
in
com.tinkerpop.gremlin.java.GremlinPipeline

Best Java code snippets using com.tinkerpop.gremlin.java.GremlinPipeline.as (Showing top 6 results out of 315)

origin: socialsensor/graphdb-benchmarks

@Override
public void shortestPath(final Vertex fromNode, Integer node)
{
  final Vertex v2 = titanGraph.getVertices(NODE_ID, node).iterator().next();
  @SuppressWarnings("rawtypes")
  final GremlinPipeline<String, List> pathPipe = new GremlinPipeline<String, List>(fromNode).as(SIMILAR)
    .out(SIMILAR).loop(SIMILAR, new PipeFunction<LoopBundle<Vertex>, Boolean>() {
      // @Override
      public Boolean compute(LoopBundle<Vertex> bundle)
      {
        return bundle.getLoops() < 5 && !bundle.getObject().equals(v2);
      }
    }).path();
}
origin: org.jboss.windup.rules.apps/rules-java

  @Override
  public void query(GraphRewrite event, GremlinPipeline<Vertex, Vertex> pipeline)
  {
    Predicate regexPredicate = new Predicate()
    {
      @Override
      public boolean evaluate(Object first, Object second)
      {
        return ((String) first).matches((String) second);
      }
    };
    pipeline.as("result")
          .out(FileReferenceModel.FILE_MODEL)
          .out(JavaSourceFileModel.JAVA_CLASS_MODEL)
          .has(JavaClassModel.QUALIFIED_NAME,
                regexPredicate,
                compiledTypeFilterPattern.pattern())
          .back("result");
  }
}
origin: org.jboss.windup.rules.apps/rules-java

public boolean isMavenConfiguration(XmlFileModel resource)
{
  return (new GremlinPipeline<Vertex, Vertex>(resource.asVertex())).in("xmlFacet").as("facet")
        .has(WindupVertexFrame.TYPE_PROP, this.getTypeValueForSearch()).back("facet")
        .iterator().hasNext();
}
origin: apache/incubator-atlas

private List<Vertex> executeQuery() {
  GremlinPipeline pipeline = buildPipeline().as("root");
  Pipe expressionPipe = queryExpression.asPipe();
  // AlwaysQuery returns null for pipe
  return expressionPipe == null ? pipeline.toList() :
      pipeline.add(expressionPipe).back("root").toList();
}
origin: org.jboss.windup.rules.apps/rules-java

public MavenProjectModel getMavenConfigurationFromResource(XmlFileModel resource)
{
  @SuppressWarnings("unchecked")
  Iterator<Vertex> v = (Iterator<Vertex>) (new GremlinPipeline<Vertex, Vertex>(resource.asVertex()))
        .in("xmlFacet").as("facet")
        .has(WindupVertexFrame.TYPE_PROP, this.getTypeValueForSearch()).back("facet")
        .iterator();
  if (v.hasNext())
  {
    return getGraphContext().getFramed().frame(v.next(), this.getType());
  }
  return null;
}
origin: org.jboss.windup.rules.apps/rules-java

pipeline.has(WindupVertexFrame.TYPE_PROP, Text.CONTAINS, InlineHintModel.TYPE);
pipeline.as("inlineHintVertex");
pipeline.out(InlineHintModel.FILE_LOCATION_REFERENCE).has(WindupVertexFrame.TYPE_PROP, Text.CONTAINS,
      JavaTypeReferenceModel.TYPE);
com.tinkerpop.gremlin.javaGremlinPipelineas

Javadoc

Wrap the previous step in an AsPipe. Useful for naming steps and is used in conjunction with various other steps including: loop, select, back, table, etc.

Popular methods of GremlinPipeline

  • <init>
  • out
    Add an OutPipe to the end of the Pipeline. Emit the adjacent outgoing vertices of the incoming verte
  • has
    Add an IdFilterPipe, LabelFilterPipe, or PropertyFilterPipe to the end of the Pipeline. If the incom
  • in
    Add a InPipe to the end of the Pipeline. Emit the adjacent incoming vertices for the incoming vertex
  • add
    Add an arbitrary pipe to the GremlinPipeline
  • iterator
  • back
    Add a BackFilterPipe to the end of the Pipeline. The object that was seen namedSteps ago is emitted.
  • both
    Add a BothPipe to the end of the Pipeline. Emit both the incoming and outgoing adjacent vertices for
  • dedup
    Add a DuplicateFilterPipe to the end of the Pipeline. Will only emit the object if the object genera
  • hasNot
    Add an IdFilterPipe, LabelFilterPipe, or PropertyFilterPipe to the end of the Pipeline. If the incom
  • outE
    Add an OutEdgesPipe to the end of the Pipeline. Emit the outgoing edges for the incoming vertex.
  • toList
    Return a list of all the objects in the pipeline.
  • outE,
  • toList,
  • V,
  • _,
  • addPipe,
  • aggregate,
  • bothE,
  • count,
  • enablePath

Popular in Java

  • Making http requests using okhttp
  • scheduleAtFixedRate (Timer)
  • getSupportFragmentManager (FragmentActivity)
  • onRequestPermissionsResult (Fragment)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • JLabel (javax.swing)
  • JOptionPane (javax.swing)
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now