Examples of clone()


Examples of org.eclipse.persistence.queries.QueryResultsCachePolicy.clone()

            for (List<DatabaseQuery> queries : getQueries().values()) {
                for (DatabaseQuery query : queries) {
                    if (query.isReadQuery() && (query.getDescriptor() != null) && !query.getDescriptor().getCachePolicy().isIsolated()) {
                        ReadQuery readQuery = (ReadQuery)query;
                        if (!readQuery.shouldCacheQueryResults()) {
                            readQuery.setQueryResultsCachePolicy(defaultQueryCachePolicy.clone());
                        }
                    }
                }
            }
        }
View Full Code Here

Examples of org.eclipse.persistence.queries.ReadObjectQuery.clone()

            // The properties/query hints and setIsExecutionClone etc. is set
            // in the getReadObjectQuery.
            query = getReadObjectQuery(descriptor.getJavaClass(), primaryKeyValues, properties);
        } else {
            query.checkPrepare(session, null);
            query = (ReadObjectQuery)query.clone();
           
            // Apply the properties if there are some.
            QueryHintsHandler.apply(properties, query, session.getLoader());
           
            query.setIsExecutionClone(true);
View Full Code Here

Examples of org.eclipse.persistence.queries.ReadQuery.clone()

            }
            if (batchQuery == null) {
                batchQuery = prepareNestedBatchQuery(query);
                batchQuery.setIsExecutionClone(true);
            } else {
                batchQuery = (ReadQuery)batchQuery.clone();
                batchQuery.setIsExecutionClone(true);
            }
            query.setProperty(this, batchQuery);
        }
        return this.indirectionPolicy.valueFromBatchQuery(batchQuery, row, query, parentCacheKey);
View Full Code Here

Examples of org.eclipse.persistence.sessions.DatabaseRecord.clone()

            if (query.shouldCascadeOnlyDependentParts()) {
                // Hey I might actually want to use an inner class here... ok array for now.
                Object[] event = new Object[3];
                event[0] = Insert;
                event[1] = getInsertQuery();
                event[2] = databaseRow.clone();
                query.getSession().getCommitManager().addDataModificationEvent(this, event);
            } else {
                query.getSession().executeQuery(getInsertQuery(), databaseRow);
                if ((getHistoryPolicy() != null) && getHistoryPolicy().shouldHandleWrites()) {
                    getHistoryPolicy().mappingLogicalInsert(getInsertQuery(), databaseRow, query.getSession());
View Full Code Here

Examples of org.eclipse.persistence.sessions.Login.clone()

            if (isServerSession) {
                login = ((ServerSession)getOwnerSession()).getReadConnectionPool().getLogin();
            } else {
                login = getOwnerSession().getDatasourceLogin();
            }
            setLogin((Login)login.clone());
        }

        if (getLogin() != null) {
            if (getLogin().shouldUseExternalTransactionController()) {
                throw ValidationException.invalidSequencingLogin();
View Full Code Here

Examples of org.eclipse.swt.custom.StyleRange.clone()

        for (StyleRange highlightStyle : highlights) {
          int start = nonHighlightStyle.start;

          if ((start >= highlightStyle.start)
              && (start < (highlightStyle.start + highlightStyle.length))) {
            newStyle = (StyleRange) newStyle.clone();
            newStyle.background = HIGHLIGHTED_BACKGROUND_COLOR;
          }
        }

        nonHighlightStyles.add(newStyle);
View Full Code Here

Examples of org.eclipse.swt.graphics.ImageData.clone()

                    // perfect! it did what was expected!
                    //
                    final ImageData data = (ImageData) image.getImageData().clone();
                    return new ImageDescriptor(){
                        public ImageData getImageData() {
                            return (ImageData) data.clone();
                        }
                    };
                }
                if (bound.height < 16 || bound.width < 16) {
                    // the image is smaller than what we asked for
View Full Code Here

Examples of org.eclipse.ui.internal.registry.FileEditorMapping.clone()

        // Populate the table with the items
        IFileEditorMapping[] array = WorkbenchPlugin.getDefault()
                .getEditorRegistry().getFileEditorMappings();
        for (int i = 0; i < array.length; i++) {
            FileEditorMapping mapping = (FileEditorMapping) array[i];
            mapping = (FileEditorMapping) mapping.clone(); // want a copy
            newResourceTableItem(mapping, i, false);
        }
    }

    /**
 
View Full Code Here

Examples of org.eclipse.wst.html.core.internal.contentmodel.TapestryElementCollection.JACreater.AttrDecl.clone()

      Hashtable items = new Hashtable();
      if(o.items.size() > 0 && o.item(0) instanceof AttrDecl){
        AttrDecl one = (AttrDecl) o.item(0);
        for(int i=0; i<attributes.length; i++){
          String attribute = attributes[i];
          items.put(attribute, one.clone(attribute));
        }
      }
      o.items = items;
    }catch(CloneNotSupportedException e){
      e.printStackTrace();
View Full Code Here

Examples of org.ejbca.core.model.ca.certificateprofiles.CertificateProfile.clone()

        } else {
        // We need to clone the profile, otherwise the cache contents will be modifyable from the outside
          final CertificateProfile cprofile = profileCache.getProfileCache(entityManager).get(Integer.valueOf(id));
        try {
          if (cprofile != null) {
            returnval = (CertificateProfile)cprofile.clone();
          }
        } catch (CloneNotSupportedException e) {
          LOG.error("Should never happen: ", e);
          throw new RuntimeException(e);
        }
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.