Examples of QueryService


Examples of org.apache.oodt.cas.catalog.struct.QueryService

  }
 
  public int sizeOf(QueryExpression queryExpression) throws CatalogException {
    try {
      if (this.isQueriable()) {
        QueryService queryService = (QueryService) this.index;
        return queryService.sizeOf(queryExpression);
      }else {
        LOG.log(Level.WARNING, "Catalog '" + this + "' is not queriable");
        return 0;
      }
    }catch (Exception e) {
View Full Code Here

Examples of org.apache.oodt.cas.catalog.struct.QueryService

  }
 
  public Metadata getMetadata(TransactionId<?> transactionId) throws CatalogException {
    try {
      if (this.isQueriable()) {
        QueryService queryService = (QueryService) this.index;
        return this.getMetadataFromBuckets(queryService.getBuckets(transactionId));
      }else {
        LOG.log(Level.WARNING, "Catalog '" + this + "' is not queriable");
        return new Metadata();
      }
    }catch(Exception e) {
View Full Code Here

Examples of org.apache.oodt.cas.catalog.struct.QueryService

 
  public Map<TransactionId<?>, Metadata> getMetadata(List<TransactionId<?>> transactionIds) throws CatalogException {
    try {
      Map<TransactionId<?>, Metadata> metadataMap = new HashMap<TransactionId<?>, Metadata>();
      if (this.isQueriable()) {
        QueryService queryService = (QueryService) this.index;
        Map<TransactionId<?>, List<TermBucket>> termBucketMap = queryService.getBuckets(transactionIds);
        for (TransactionId<?> transactionId : termBucketMap.keySet())
          metadataMap.put(transactionId, this.getMetadataFromBuckets(termBucketMap.get(transactionId)));
      }else {
        LOG.log(Level.WARNING, "Catalog '" + this + "' is not queriable");
      }
View Full Code Here

Examples of org.cyclop.service.cassandra.QueryService

  @Inject
  private CassandraSessionImpl session;

  private QueryService get() {
    CassandraVersion ver = session.getCassandraVersion();
    QueryService instance = ver == CassandraVersion.VER_2_x ? defaultQs : fallbackQs;
    return instance;
  }
View Full Code Here

Examples of org.exist.soap.QueryService

* Execute: bin\run.bat org.exist.examples.soap.GetDocument
*/
public class GetDocument {

    public static void main( String[] args ) throws Exception {
        QueryService service = new QueryServiceLocator();
        Query query = service.getQuery();
    String session = query.connect("guest", "guest");
       
    byte[] data = query.getResourceData(session,
        XmldbURI.ROOT_COLLECTION + "/shakespeare/plays/hamlet.xml",
      true, false, false);
View Full Code Here

Examples of org.exist.soap.QueryService

    "</xu:modifications>";
   
    public static void main( String[] args ) throws Exception {
        AdminService adminService = new AdminServiceLocator();
        Admin admin = adminService.getAdmin();
        QueryService queryService = new QueryServiceLocator();
        Query query = queryService.getQuery();
       
    String session = admin.connect("guest", "guest");
    admin.store(session, document.getBytes(UTF_8), "UTF-8", XmldbURI.ROOT_COLLECTION + "/test/notes.xml", true);
    admin.xupdateResource(session, XmldbURI.ROOT_COLLECTION + "/test/notes.xml", xupdate);
   
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.