Package org.graphity.client.util

Examples of org.graphity.client.util.XSLTBuilder.parameter()


        {
            Resource resource = (Resource)getUriInfo().getMatchedResources().get(0);
            if (log.isDebugEnabled()) log.debug("Matched Resource: {}", resource);
            MatchedIndividual match = (MatchedIndividual)resource;

      bld.parameter("{" + GP.matchedOntClass.getNameSpace() + "}" + GP.matchedOntClass.getLocalName(), URI.create(match.getMatchedOntClass().getURI())).
            parameter("{" + GP.ontModel.getNameSpace() + "}" + GP.ontModel.getLocalName(), getSource(match.getOntModel(), true)); // $ont-model from the current Resource (with imports)
        }
       
  Object contentType = headerMap.getFirst(HttpHeaders.CONTENT_TYPE);
  if (contentType != null)
View Full Code Here


  }
  Object contentLanguage = headerMap.getFirst(HttpHeaders.CONTENT_LANGUAGE);
  if (contentLanguage != null)
  {
      if (log.isDebugEnabled()) log.debug("Writing Model using language: {}", contentLanguage.toString());
      bld.parameter("{" + GC.lang.getNameSpace() + "}" + GC.lang.getLocalName(), contentLanguage.toString());
  }

        // pass HTTP query parameters into XSLT, ignore reserved param names (as params cannot be unset)
  Iterator<Entry<String, List<String>>> it = getUriInfo().getQueryParameters().entrySet().iterator();
        while (it.hasNext())
View Full Code Here

        while (it.hasNext())
        {
            Entry<String, List<String>> entry = it.next();
            if (!getReservedParameterNames().contains(entry.getKey()))
            {
                bld.parameter(entry.getKey(), entry.getValue().get(0)); // set string value
                if (log.isDebugEnabled()) log.debug("Setting XSLT param \"{}\" from HTTP query string with value: {}", entry.getKey(), entry.getValue().get(0));
            }
            else
                if (log.isDebugEnabled()) log.debug("HTTP query string param \"{}\" is reserved in XSLT writer, ignoring", entry.getKey());
        }
View Full Code Here

                if (log.isDebugEnabled()) log.debug("HTTP query string param \"{}\" is reserved in XSLT writer, ignoring", entry.getKey());
        }

        // override the reserved parameters that need special types
  if (getUriInfo().getQueryParameters().getFirst(GC.mode.getLocalName()) != null)
      bld.parameter("{" + GC.mode.getNameSpace() + "}" + GC.mode.getLocalName(),
                    URI.create(getUriInfo().getQueryParameters().getFirst(GC.mode.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName()) != null)
      bld.parameter("{" + GC.uri.getNameSpace() + "}" + GC.uri.getLocalName(),
                URI.create(getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.endpointUri.getLocalName()) != null)
View Full Code Here

        // override the reserved parameters that need special types
  if (getUriInfo().getQueryParameters().getFirst(GC.mode.getLocalName()) != null)
      bld.parameter("{" + GC.mode.getNameSpace() + "}" + GC.mode.getLocalName(),
                    URI.create(getUriInfo().getQueryParameters().getFirst(GC.mode.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName()) != null)
      bld.parameter("{" + GC.uri.getNameSpace() + "}" + GC.uri.getLocalName(),
                URI.create(getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.endpointUri.getLocalName()) != null)
      bld.parameter("{" + GC.endpointUri.getNameSpace() + "}" + GC.endpointUri.getLocalName(),
                    URI.create(getUriInfo().getQueryParameters().getFirst(GC.endpointUri.getLocalName())));
View Full Code Here

                    URI.create(getUriInfo().getQueryParameters().getFirst(GC.mode.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName()) != null)
      bld.parameter("{" + GC.uri.getNameSpace() + "}" + GC.uri.getLocalName(),
                URI.create(getUriInfo().getQueryParameters().getFirst(GC.uri.getLocalName())));
  if (getUriInfo().getQueryParameters().getFirst(GC.endpointUri.getLocalName()) != null)
      bld.parameter("{" + GC.endpointUri.getNameSpace() + "}" + GC.endpointUri.getLocalName(),
                    URI.create(getUriInfo().getQueryParameters().getFirst(GC.endpointUri.getLocalName())));

  return bld;
    }
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.