Package eu.admire.registry.function

Examples of eu.admire.registry.function.FunctionDescriptor


 
 
  @Test
  public void testLookupFunctionName() throws LookupFailedException
  {
    FunctionDescriptor function = registry.lookupFunction("FunctionTest2");
    Assert.assertNotNull(function);
   
    Assert.assertTrue(function.getName().equals(mFunctionDescriptor.getName()));
    Assert.assertTrue(function.getParameters().keySet().size()==mFunctionDescriptor.getParameters().keySet().size());
    Assert.assertTrue(function.getParameters().keySet().size()==mFunctionDescriptor.getParameters().keySet().size());
  }
View Full Code Here


    // Query results: ?input ?type ?index
    List<ResultSet> results = mApp.queryAll(generateInputQuery,
        generateFunctionReturnQuery);
    URI functionLocation = null;
    FunctionDescriptor io = null;
    Map<String, Parameter> inputs = new HashMap<String, Parameter>();
    Parameter output = null;
    if (results.size() >= 2) {
      ResultSet resultset = results.get(0);
      while (resultset.next()) {
View Full Code Here

  }

  @Override
  public FunctionDescriptor lookupFunction(String name)
      throws LookupFailedException {
    FunctionDescriptor descriptor = null;
    try {
      LOG.debug("Looking up function '" + name + "' information.");
      String function = mQueries.queryFunction(name);
      if (function != null) {
        LOG.debug("Found function '" + name
View Full Code Here

                }
            }
            else
            {
                // find out if it's a function
                FunctionDescriptor function = mFunctionRegistry.lookupFunction(name);
                LOG.debug("Function registry returned : " + function);
                if (function != null)
                {
                    DispelObject object = new DispelObject();
                    object.type = DispelObjectType.FUNCTION;
                    object.name = name;
                    object.dispel = lookupImplementation(function.getLocation());
                    usedObjects.add(object);
                }
                else
                {
                    // check if it's stored in-memory
View Full Code Here

    Map<String, Parameter> inputs = new HashMap<String, Parameter>();
    inputs.put("input1", input1);
    inputs.put("input2", input2);
    inputs.put("input3", input3);

    FunctionDescriptor function;
    URI location = new URI("http://admire.function.examle.org/");
    function = new SimpleRDFFunctionDescriptor("DummyFunction1", inputs, output, location);
    registry.registerFunction(function);

  }
View Full Code Here

TOP

Related Classes of eu.admire.registry.function.FunctionDescriptor

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.