congrats Icon
New! Announcing our next generation AI code completions
Read here
Tabnine Logo
QueryBuilderFind.piped
Code IndexAdd Tabnine to your IDE (free)

How to use
piped
method
in
org.jboss.windup.config.query.QueryBuilderFind

Best Java code snippets using org.jboss.windup.config.query.QueryBuilderFind.piped (Showing top 15 results out of 315)

origin: org.jboss.windup.rules.apps/windup-rules-java-ee

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.textRegex(REGEX_HIBERNATE));
      Traversal<?, ?> systemIDQuery = event.getGraphContext().getQuery(DoctypeMetaModel.class)
            .getRawTraversal()
            .has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.textRegex(REGEX_HIBERNATE));
      GraphTraversal<Vertex, Vertex> systemIdPipeline = new GraphTraversalSource(event.getGraphContext().getGraph()).V(systemIDQuery.toList());
      pipeline.union(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: org.jboss.windup.rules.apps/windup-rules-java-ee

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.textRegex(REGEX_HIBERNATE));
      Traversal<?, ?> systemIDQuery = event.getGraphContext().getQuery(DoctypeMetaModel.class)
            .getRawTraversal().has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.textRegex(REGEX_HIBERNATE));
      GraphTraversal<Vertex, Vertex> systemIdPipeline = new GraphTraversalSource(event.getGraphContext().getGraph()).V(systemIDQuery.toList());
      pipeline.union(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: org.jboss.windup.rules.apps/rules-java-ee

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GremlinPipeline<Vertex, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.REGEX, hibernateRegex);
      FramedGraphQuery systemIDQuery = event.getGraphContext().getQuery().type(DoctypeMetaModel.class)
            .has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.REGEX, hibernateRegex);
      GremlinPipeline<Vertex, Vertex> systemIdPipeline = new GremlinPipeline<>(systemIDQuery.vertices());
      pipeline.add(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: org.jboss.windup.rules.apps/rules-java-ee

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GremlinPipeline<Vertex, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.REGEX, hibernateRegex);
      FramedGraphQuery systemIDQuery = event.getGraphContext().getQuery().type(DoctypeMetaModel.class)
            .has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.REGEX, hibernateRegex);
      GremlinPipeline<Vertex, Vertex> systemIdPipeline = new GremlinPipeline<>(systemIDQuery.vertices());
      pipeline.add(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: windup/windup

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.textRegex(REGEX_HIBERNATE));
      Traversal<?, ?> systemIDQuery = event.getGraphContext().getQuery(DoctypeMetaModel.class)
            .getRawTraversal().has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.textRegex(REGEX_HIBERNATE));
      GraphTraversal<Vertex, Vertex> systemIdPipeline = new GraphTraversalSource(event.getGraphContext().getGraph()).V(systemIDQuery.toList());
      pipeline.union(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: windup/windup

@Override
public ConditionBuilder when()
{
  QueryGremlinCriterion doctypeSearchCriterion = new QueryGremlinCriterion()
  {
    @Override
    public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
    {
      pipeline.has(DoctypeMetaModel.PROPERTY_PUBLIC_ID, Text.textRegex(REGEX_HIBERNATE));
      Traversal<?, ?> systemIDQuery = event.getGraphContext().getQuery(DoctypeMetaModel.class)
            .getRawTraversal()
            .has(DoctypeMetaModel.PROPERTY_SYSTEM_ID, Text.textRegex(REGEX_HIBERNATE));
      GraphTraversal<Vertex, Vertex> systemIdPipeline = new GraphTraversalSource(event.getGraphContext().getGraph()).V(systemIDQuery.toList());
      pipeline.union(systemIdPipeline);
      pipeline.dedup();
    }
  };
  return Query.fromType(DoctypeMetaModel.class).piped(doctypeSearchCriterion);
}
origin: org.jboss.windup.reporting/windup-reporting-api

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(InlineHintModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String HINT_STEP = "hintModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(HINT_STEP);
        pipeline.out(InlineHintModel.FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(HINT_STEP);
      }
    });
  }
  q.withProperty(InlineHintModel.HINT, QueryPropertyComparisonType.REGEX, messagePattern);
  return q.evaluate(event, context);
}
origin: windup/windup

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(InlineHintModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String HINT_STEP = "hintModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(HINT_STEP);
        pipeline.out(InlineHintModel.FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(HINT_STEP);
      }
    });
  }
  q.withProperty(InlineHintModel.HINT, QueryPropertyComparisonType.REGEX, messagePattern);
  return q.evaluate(event, context);
}
origin: org.jboss.windup.reporting/windup-reporting-api

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(ClassificationModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String CLASSIFICATION_STEP = "classificationModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(CLASSIFICATION_STEP);
        pipeline.out(ClassificationModel.FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(CLASSIFICATION_STEP);
      }
    });
  }
  q.withProperty(ClassificationModel.CLASSIFICATION, QueryPropertyComparisonType.REGEX, classificationPattern);
  return q.evaluate(event, context);
}
origin: windup/windup

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(TechnologyTagModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String TECHNOLOGYTAG_STEP = "technologyTagModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(TECHNOLOGYTAG_STEP);
        pipeline.out(TechnologyTagModel.TECH_TAG_TO_FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(TECHNOLOGYTAG_STEP);
      }
    });
  }
  q.withProperty(TechnologyTagModel.NAME, QueryPropertyComparisonType.REGEX, namePattern);
  return q.evaluate(event, context);
}
origin: org.jboss.windup.reporting/windup-reporting-api

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(TechnologyTagModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String TECHNOLOGYTAG_STEP = "technologyTagModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(TECHNOLOGYTAG_STEP);
        pipeline.out(TechnologyTagModel.TECH_TAG_TO_FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(TECHNOLOGYTAG_STEP);
      }
    });
  }
  q.withProperty(TechnologyTagModel.NAME, QueryPropertyComparisonType.REGEX, namePattern);
  return q.evaluate(event, context);
}
origin: windup/windup

@Override
public boolean evaluate(GraphRewrite event, EvaluationContext context)
{
  QueryBuilderFind q = Query.fromType(ClassificationModel.class);
  if (StringUtils.isNotBlank(filename))
  {
    q.piped(new QueryGremlinCriterion()
    {
      private static final String CLASSIFICATION_STEP = "classificationModel";
      @Override
      public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
      {
        pipeline.as(CLASSIFICATION_STEP);
        pipeline.out(ClassificationModel.FILE_MODEL);
        pipeline.has(FileModel.FILE_NAME, filename);
        pipeline.select(CLASSIFICATION_STEP);
      }
    });
  }
  q.withProperty(ClassificationModel.CLASSIFICATION, QueryPropertyComparisonType.REGEX, classificationPattern);
  return q.evaluate(event, context);
}
origin: org.jboss.windup.rules.apps/rules-java

@Override
public Configuration getConfiguration(GraphContext context)
{
  QueryGremlinCriterion shouldDecompileCriterion = new ShouldDecompileCriterion();
  
  return ConfigurationBuilder.begin()
  .addRule()
  .when(Query.fromType(ArchiveModel.class).piped(shouldDecompileCriterion))
  .perform(
    new ProcyonDecompilerOperation()
    .and(IterationProgress.monitoring("Decompiled archive: ", 1))
    .and(Commit.every(1))
  )
  .otherwise(Log.message(Level.WARN, "No archives to decompile."));
}
// @formatter:on
origin: windup/windup

@Override
public Configuration getConfiguration(RuleLoaderContext ruleLoaderContext)
{
  return ConfigurationBuilder.begin()
  .addRule()
  .when(Query.fromType(WindupConfigurationModel.class)
      .piped((GraphRewrite event, GraphTraversal<?, Vertex> pipeline) -> {
        pipeline.out(WindupConfigurationModel.INPUT_PATH);
        pipeline.has(FileModel.IS_DIRECTORY, true);
      })
  )
  .perform(new RecurseDirectoryAndAddFiles())
  .addRule()
  .when(Query.fromType(FileModel.class)
    .withProperty(FileModel.IS_DIRECTORY, false)
    .withProperty(FileModel.FILE_PATH, QueryPropertyComparisonType.REGEX, ZipUtil.getEndsWithZipRegularExpression())
  )
  .perform(
    new AddArchiveReferenceInformation()
  );
}
// @formatter:on
origin: org.jboss.windup.rules.apps/windup-rules-java-api

@Override
public Configuration getConfiguration(RuleLoaderContext ruleLoaderContext)
{
  return ConfigurationBuilder.begin()
  .addRule()
  .when(Query.fromType(WindupConfigurationModel.class)
      .piped((GraphRewrite event, GraphTraversal<?, Vertex> pipeline) -> {
        pipeline.out(WindupConfigurationModel.INPUT_PATH);
        pipeline.has(FileModel.IS_DIRECTORY, true);
      })
  )
  .perform(new RecurseDirectoryAndAddFiles())
  .addRule()
  .when(Query.fromType(FileModel.class)
    .withProperty(FileModel.IS_DIRECTORY, false)
    .withProperty(FileModel.FILE_PATH, QueryPropertyComparisonType.REGEX, ZipUtil.getEndsWithZipRegularExpression())
  )
  .perform(
    new AddArchiveReferenceInformation()
  );
}
// @formatter:on
org.jboss.windup.config.queryQueryBuilderFindpiped

Popular methods of QueryBuilderFind

  • withProperty
  • evaluate
  • excludingType
    Excludes Vertices that are of the provided type.
  • or
  • withoutProperty

Popular in Java

  • Parsing JSON documents to java classes using gson
  • runOnUiThread (Activity)
  • addToBackStack (FragmentTransaction)
  • onCreateOptionsMenu (Activity)
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • BasicDataSource (org.apache.commons.dbcp)
    Basic implementation of javax.sql.DataSource that is configured via JavaBeans properties. This is no
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Sublime Text for Python
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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