Examples of Factory


Examples of pl.edu.amu.wmi.daut.re.NumericalRangeOperator.Factory

    /**
     * Test fabryki.
     */
    public final void testFactory() {
        Factory factory = new Factory();
        assertEquals(factory.numberOfParams(), 2);
        ArrayList<String> params = new ArrayList<String>();
        params.add(0, "100");
        params.add(1, "200");
        assertEquals(factory.createOperator(params).getClass(),
                new NumericalRangeOperator(100, 200).getClass());
    }
View Full Code Here

Examples of pl.edu.amu.wmi.daut.re.OptionalityOperator.Factory

    /**
* Test fabryki.
*/
    public final void testFactory() {

        Factory factory = new Factory();
        ArrayList<String> params = new ArrayList<String>();
        assertEquals(factory.createOperator(params).getClass(),
            new OptionalityOperator().getClass());
    }
View Full Code Here

Examples of pl.edu.amu.wmi.daut.re.TabOperator.Factory

    /**
     * Test fabryki.
     */
    public final void testFactory() {

        Factory factory = new Factory();
        RegexpOperator operator2 = factory.createOperator(new ArrayList<String>());
        int arity = operator2.arity();
        assertEquals(arity, 0);

    }
View Full Code Here

Examples of pl.edu.amu.wmi.daut.re.WhitespaceOperator.Factory

    /**
     * Test fabryki.
     */
    public void testFactory() {

        Factory factory = new Factory();
        RegexpOperator operator2 = factory.createOperator(new ArrayList<String>());
        int arity = operator2.arity();
        assertEquals(arity, 0);

    }
View Full Code Here

Examples of play.db.Model.Factory

      // Proceed only if searchable
      if (!MappingUtil.isSearchable(modelClass)) {
        continue;
      }

      final Factory factory = Model.Manager.factoryFor(modelClass);
      final long count = factory.count(null, null, null);

      // Defensively avoid overflow leading to infinite loop below
      if (count > Integer.MAX_VALUE) {
        throw new RuntimeException(String.format("Number of entities %s to index is too large (%d)", modelClass, count));
      }

      Logger.info("Reindexing %s entities of type %s", count, modelClass);

      long offset = 0;
      // loop over pages
      while (offset < count) {
        final List results = factory.fetch((int) offset, PAGE_SIZE, null, null, null, null, null);
        // loop over individual entities within one page
        for (final Object o : results) {
          ElasticSearch.index((Model) o, deliveryMode);
        }
        offset += PAGE_SIZE;
View Full Code Here

Examples of resources.digesters.Factory

 
  public static void load(String rootDir) throws SimulationException
  {
    try
    {
      Factory factory = new FactoryrootDir + File.separator + "simulation.xml",
                      rootDir + File.separator + "simulation-rules.xml");
      if ( factory == null )
        throw new SimulationException"No pudo crearse la factor�a para " +
                        "levantar la simulaci�n." );
 
      simulation = (Simulation)factory.digest();     
     
      if (simulation == null)
        throw new SimulationException( "No pudo cargarse la simulaci�n." );
    }
    catch (IOException e)
View Full Code Here

Examples of restx.factory.Factory

    /**
     * A shortcut for new RestxSpecRule("/api", 8076, queryByClass(WebServerSupplier.class), Factory.getInstance())
     */
    public static RestxSpecTestServer newInstance() {
        Factory f = Factory.getInstance();
        return new RestxSpecTestServer("/api", 8076, f.getComponent(WebServerSupplier.class), f);
    }
View Full Code Here

Examples of spoon.reflect.Factory

  public CtMethod<?> getCallback(SymbolicInstance<?> instance,
      Class<?> clazz, String methodName) {
    CtTypeReference<?> type = instance.getConcreteType();
    CtMethod<?> method = null;
    if (clazz.isAssignableFrom(type.getActualClass())) {
      Factory factory = type.getFactory();
      CtSimpleType<?> simpleType = factory.Type().getFactory().Class()
          .create(type.getQualifiedName());
      method = ((CtType<?>) simpleType).getMethod(methodName, factory
          .Type().createReference(clazz));
    }
    return method;
  }
View Full Code Here

Examples of steal.examples.expression.factory.Factory

  }
 
  public void m() {}
 
  public static void main(String[] args) {
    Factory f=new FactoryImpl();
   
    Expr expr=new Expr(f);
    Expression e=expr.expression();
   
    Main.get().m();
View Full Code Here

Examples of yalp.db.Model.Factory

        public Model findById(String id) throws Exception {
            if (id == null) {
                return null;
            }

            Factory factory =  Model.Manager.factoryFor(entityClass);
            Object boundId = Binder.directBind(id, factory.keyType());
            return factory.findById(boundId);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.