Package com.getperka.flatpack.search

Examples of com.getperka.flatpack.search.SearchTypeSource


        /*
         * At least one TypeSource is required. The TypeSources associated with a FlatPack stack
         * determine the complete set of entity types that can be processed. This SearchTypeSource
         * scans the classpath for HasUuid subtypes.
         */
        .addTypeSource(new SearchTypeSource("com.getperka.flatpack.demo.server"))
        .withSecurityPolicy(securityPolicy)
        .withPrettyPrint(true)
        /*
         * A PrincipalMapper is optional and, if present, enables the use principal-based property
         * access restrictions whereby certain Principals are allowed to mutate only specific
View Full Code Here


  @Test
  public void test() throws Exception {
    Method method = ApiDescriberTest.class.getDeclaredMethod("sampleMethod");

    FlatPack flatpack = FlatPack.create(new Configuration()
        .addTypeSource(new SearchTypeSource("com.getperka.flatpack")));
    ApiDescription description = new ApiDescriber(flatpack, Collections.singletonList(method))
        .describe();

    EntityDescription toCheck = null;
    for (EntityDescription desc : description.getEntities()) {
View Full Code Here

      @Flag(tag = "dialect", help = "The source dialect to use", defaultValue = "js") String dialect,
      @Flag(tag = "out", help = "The directory to generate source into", defaultValue = ".") File out)
      throws IOException {

    Unpacker unpacker = FlatPack.create(new Configuration()
        .addTypeSource(new SearchTypeSource("com.getperka.flatpack")))
        .getUnpacker();

    logger.info("Retrieving {}", source);
    Reader reader = new InputStreamReader(source.toURL().openStream(), Charset.forName("UTF8"));
View Full Code Here

TOP

Related Classes of com.getperka.flatpack.search.SearchTypeSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.