コード例 #1
0
  /**
   * Connects this instance to the given instance using role "ordered pairs". If the given instance
   * is null, nothing happens.
   *
   * @param orderedPairs the instance to connect
   * @throws PDStoreException
   */
  public void addOrderedPairs(GUID orderedPairs) throws PDStoreException {

    if (orderedPairs != null) {

      pdWorkingCopy.addLink(this.id, roleOrderedPairsId, orderedPairs);
    }
  }
コード例 #2
0
 /**
  * Returns the instance(s) connected to this instance through the role "ordered pairs".
  *
  * @return the connected instance(s)
  * @throws PDStoreException
  */
 public Collection<PDOrderedPair> getOrderedPairss() throws PDStoreException {
   Set<PDOrderedPair> result = new HashSet<PDOrderedPair>();
   GUID PDOrderedPairTypeId = new GUID("b3ba85348e0ede11980f9a097666e103");
   pdWorkingCopy.getInstances(
       this, roleOrderedPairsId, PDOrderedPair.class, PDOrderedPairTypeId, result);
   return result;
 }
コード例 #3
0
 /**
  * Sets the name of this instance. In PDStore every instance can be given a name. If the instance
  * already has a name, the name will be overwritten. If the given name is null, an existing name
  * will be removed.
  *
  * @return name the new instance name
  * @throws PDStoreException
  */
 public void setName(String name) throws PDStoreException {
   pdWorkingCopy.setName(id, name);
 }
コード例 #4
0
 /**
  * Gets the name of this instance. In PDStore every instance can be given a name.
  *
  * @return name the instance name
  * @throws PDStoreException
  */
 public String getName() throws PDStoreException {
   return pdWorkingCopy.getName(id);
 }
コード例 #5
0
 /**
  * Loads an instance object of this type into a cache. If the instance is already in the cache,
  * the cached instance is returned.
  *
  * @param PDWorkingCopy pdWorkingCopy to load the instance into
  * @param id GUID of the instance Do not directly call this method. Use the newInstance() method
  *     in PDCache which would call this method
  */
 public static PDOrder load(PDWorkingCopy pdWorkingCopy, GUID id) {
   PDInstance instance = pdWorkingCopy.load(typeId, id);
   return (PDOrder) instance;
 }
コード例 #6
0
 /**
  * Connects this instance to the given instance using role "ordered pairs". If there is already an
  * instance connected to this instance through role "ordered pairs", the link will be overwritten.
  * If the given instance is null, an existing link is removed."
  *
  * @param orderedPairs the instance to connect
  * @throws PDStoreException
  */
 public void setOrderedPairs(GUID orderedPairs) throws PDStoreException {
   pdWorkingCopy.setLink(this.id, roleOrderedPairsId, orderedPairs);
 }
コード例 #7
0
 /**
  * Removes the link from this instance through role "ordered pairs" to the given instance, if the
  * link exists. If there is no such link, nothing happens.orderedPairs.getId() If the given
  * instance is null, nothing happens.
  *
  * @throws PDStoreException
  */
 public void removeOrderedPairs(Object orderedPairs) throws PDStoreException {
   if (orderedPairs == null) return;
   pdWorkingCopy.removeLink(this.id, roleOrderedPairsId, orderedPairs);
 }
コード例 #8
0
 /**
  * Removes the link from this instance through role "ordered pairs".
  *
  * @throws PDStoreException
  */
 public void removeOrderedPairs() throws PDStoreException {
   pdWorkingCopy.removeLink(
       this.id, roleOrderedPairsId, pdWorkingCopy.getInstance(this, roleOrderedPairsId));
 }
コード例 #9
0
 /**
  * Returns the instance connected to this instance through the role "ordered pairs".
  *
  * @return the connected instance
  * @throws PDStoreException
  */
 public PDOrderedPair getOrderedPairs() throws PDStoreException {
   return (PDOrderedPair) pdWorkingCopy.getInstance(this, roleOrderedPairsId);
 }
コード例 #10
0
 /**
  * Removes the icon of this instance. In PDStore every instance can be given an icon. If the
  * instance does not have an icon, nothing happens.
  *
  * @throws PDStoreException
  */
 public void removeIcon() throws PDStoreException {
   pdWorkingCopy.removeIcon(id);
 }
コード例 #11
0
 /**
  * Sets the icon of this instance. In PDStore every instance can be given an icon. If the instance
  * already has an icon, the icon will be overwritten. If the given icon is null, an existing icon
  * will be removed.
  *
  * @return icon the new instance icon
  * @throws PDStoreException
  */
 public void setIcon(Blob icon) throws PDStoreException {
   pdWorkingCopy.setIcon(id, icon);
 }
コード例 #12
0
 /**
  * Gets the icon of this instance. In PDStore every instance can be given an icon.
  *
  * @return icon the instance icon
  * @throws PDStoreException
  */
 public Blob getIcon() throws PDStoreException {
   return pdWorkingCopy.getIcon(id);
 }