com.ibm.commerce.foundation.server.services.dataaccess.bom.mediator

Interface ChangeBusinessObjectPartMediator

    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String COPYRIGHT
      IBM Copyright notice field.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      void applyChanges()
      Applies changes in the physical data continer to the physical persistent storage.
      void create(java.lang.Object aNoun, java.lang.Object aNounPart)
      Creates the physical entities corresponding to the logical noun part and adds to the root physical entity.
      void delete(java.lang.Object aNoun, java.lang.Object aNounPart)
      Deletes the logical noun part.
      java.lang.Object findPhysicalEntity(java.lang.Object aNoun, java.lang.Object aNounPart)
      Finds the physical entity corresponding to the noun in the physical data container associated with this mediator.
      java.util.List getNounParts()
      Returns the list of noun parts associated with this mediator
      java.lang.String[] getNounPartXPaths()
      Returns the NounPart part XPaths supported by this mediator.
      PhysicalDataContainer getPhysicalDataContainer()
      Returns the physical data container associated with this mediator
      java.lang.String getUpdateAccessProfile()
      This method returns the update access profile defined for a particular part mediator.
      void initialize(java.util.Map aMapNounPart, PhysicalDataContainer aParentPhysicalDataContainer)
      Initializes the change part mediator and sets the parent physical data container
      void setUpdateAccessProfile(java.lang.String astrAccessProfile)
      This method sets the update access profile which defined in the wc-business-object-mediator.xml file
      void update(java.lang.Object aNoun, java.lang.Object aNounPart)
      Updates the logical noun part.
      java.util.List validateChange(java.lang.Object aNoun, java.lang.Object aNounPart)
      Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized.
      java.util.List validateCreate(java.lang.Object aNoun, java.lang.Object aNounPart)
      Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized.
      java.util.List validateDelete(java.lang.Object aNoun, java.lang.Object aNounPart)
      Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized.
    • Field Detail

      • COPYRIGHT

        static final java.lang.String COPYRIGHT
        IBM Copyright notice field.
        See Also:
        Constant Field Values
    • Method Detail

      • getNounParts

        java.util.List getNounParts()
        Returns the list of noun parts associated with this mediator
        Returns:
        The noun parts
      • initialize

        void initialize(java.util.Map aMapNounPart,
                        PhysicalDataContainer aParentPhysicalDataContainer)
                 throws java.lang.Exception
        Initializes the change part mediator and sets the parent physical data container
        Parameters:
        aMapNounPart - The noun part details
        aParentPhysicalDataContainer - The parent container
        Throws:
        java.lang.Exception
      • getPhysicalDataContainer

        PhysicalDataContainer getPhysicalDataContainer()
        Returns the physical data container associated with this mediator
        Returns:
        The physical data container
      • validateCreate

        java.util.List validateCreate(java.lang.Object aNoun,
                                      java.lang.Object aNounPart)
                               throws AbstractApplicationException
        Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized. If it is already present the creation process is invalid and will cause duplicates.
        Parameters:
        aNoun - The noun
        aNounPart - The noun part
        Returns:
        List of validation errors
        Throws:
        AbstractApplicationException
      • validateChange

        java.util.List validateChange(java.lang.Object aNoun,
                                      java.lang.Object aNounPart)
                               throws AbstractApplicationException
        Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized.
        Parameters:
        aNoun - The noun
        aNounPart - The noun part
        Returns:
        List of validation errors
        Throws:
        AbstractApplicationException
      • validateDelete

        java.util.List validateDelete(java.lang.Object aNoun,
                                      java.lang.Object aNounPart)
                               throws AbstractApplicationException
        Performs basic validation if the physical entity corresponding to the noun part is already present in the physical data container that was initialized.
        Parameters:
        aNoun - The noun
        aNounPart - The noun part
        Returns:
        List of validation errors
        Throws:
        AbstractApplicationException
      • create

        void create(java.lang.Object aNoun,
                    java.lang.Object aNounPart)
             throws AbstractApplicationException
        Creates the physical entities corresponding to the logical noun part and adds to the root physical entity.
        Parameters:
        aNoun - The logical noun that contains the noun part
        aNounPart - The noun part for which the corresponding physical entities needs to be created
        Throws:
        AbstractApplicationException
      • update

        void update(java.lang.Object aNoun,
                    java.lang.Object aNounPart)
             throws AbstractApplicationException
        Updates the logical noun part.
        Parameters:
        aNoun - The logical noun that contains the noun part
        aNounPart - The noun part for which the corresponding physical entities needs to be updated
        Throws:
        AbstractApplicationException
      • delete

        void delete(java.lang.Object aNoun,
                    java.lang.Object aNounPart)
             throws AbstractApplicationException
        Deletes the logical noun part. The delete action on the logical noun part is copied to the physical implementation. Deletion of a logical noun part may result in the update of a physical entity in the form of a mark for delete or may result in an actual delete from the physical data store.
        Parameters:
        aNoun - The logical noun having the noun part to be deleted
        aNounPart - The logical noun part that needs to be deleted
        Throws:
        AbstractApplicationException
      • findPhysicalEntity

        java.lang.Object findPhysicalEntity(java.lang.Object aNoun,
                                            java.lang.Object aNounPart)
                                     throws AbstractApplicationException
        Finds the physical entity corresponding to the noun in the physical data container associated with this mediator.
        Parameters:
        aNoun - The logical noun
        aNounPart - The logical noun part
        Returns:
        The physical entity, null if not found
        Throws:
        AbstractApplicationException
      • getNounPartXPaths

        java.lang.String[] getNounPartXPaths()
        Returns the NounPart part XPaths supported by this mediator.
        Returns:
        an array of NounPart part XPath
      • setUpdateAccessProfile

        void setUpdateAccessProfile(java.lang.String astrAccessProfile)
        This method sets the update access profile which defined in the wc-business-object-mediator.xml file
        Parameters:
        astrAccessProfile - The name of the aceess profile.
      • getUpdateAccessProfile

        java.lang.String getUpdateAccessProfile()
        This method returns the update access profile defined for a particular part mediator.
        Returns:
        The name of the access profile.