Interface IBmObject

    • Method Detail

      • bmGetId

        long bmGetId()
        Gets the object's ID.
        Returns:
        the object's ID or -1L if the object has never been attached to BM.
      • bmGetEngine

        IBmEngine bmGetEngine()
        Gets the engine the object is managed by.
        Returns:
        the engine or null if the object is not attached to BM.
      • bmGetTransaction

        IBmTransaction bmGetTransaction()
        Gets the transaction this object is associated with.
        Returns:
        the transaction or null if the object is not associated with a transaction.
      • bmIsTop

        boolean bmIsTop()
        Checks if the object is top-level.
        Returns:
        true if the object is top-level, otherwise false.
      • bmGetFqn

        String bmGetFqn()
        Gets FQN of this object. If this object is not attached to BM or not a top object, an exception is thrown.
        Returns:
        the FQN, not null.
      • bmGetTopObject

        IBmObject bmGetTopObject()
        Gets the corresponding top-level object. If the object is not attached to BM an exception is thrown.
        Returns:
        the corresponding top-level object, can be null in case if IBmObject is global and the object was removed out of storage.
      • bmGetUri

        org.eclipse.emf.common.util.URI bmGetUri()
        Gets URI of this object.
        Returns:
        the URI or null.
      • bmGetUriAsString

        String bmGetUriAsString()
        Gets URI of this object in the form of a string.
        This method could be used as an optimization to not overload the (URI pool.
        Returns:
        the URI or null.
      • bmGetResourceId

        int bmGetResourceId()
        Gets resource ID this object belongs to. If the object is not attached to BM an exception is thrown.
        Returns:
        the resource ID.
      • bmGetReferences

        Collection<IBmCrossReference> bmGetReferences()
        Gets the references pointing to this object.
        Returns:
        references to this object, never null.
      • bmGetProperty

        String bmGetProperty​(String property)
        Gets the specified property value.
        Parameters:
        property - The property to get value. May not be null.
        Returns:
        the property value if set, null otherwise.
      • bmGetProperties

        Map<String,​String> bmGetProperties()
        Gets map containing all the object's properties.
        Returns:
        a map containing all the object's properties, never null.
      • bmSetProperty

        void bmSetProperty​(String property,
                           String value)
        Sets the specified property value.
        Parameters:
        property - The property to set value. May not be null.
        value - The value to set. May be null.
      • bmReadBinaryData

        InputStream bmReadBinaryData​(String streamId)
        Gets a stream for read access to the binary data.
        Parameters:
        streamId - stream ID to gain read access for.
        Returns:
        InputStream stream associated with this object.
      • bmWriteBinaryData

        OutputStream bmWriteBinaryData​(String streamId)
        Gets a stream for write access to the binary data. If the object is not attached to BM this method throws an exception.
        Parameters:
        streamId - The stream ID to gain write access to. May not be null.
        Returns:
        OutputStream stream associated with this object
        See Also:
        #bmWriteBinaryData(String, boolean)
      • bmRemoveBinaryData

        void bmRemoveBinaryData​(String streamId)
        Removes binary data. If the object is not attached to BM this method throws an exception.
        Parameters:
        streamId - The ID of the data stream to remove. May not be null.
      • bmListBinaryData

        List<String> bmListBinaryData()
        Gets the list of binary data streams. If the object is not attached to BM this method throws an exception.
        Returns:
        the list of the binary data streams, never null.
      • bmIsTransient

        boolean bmIsTransient()
        Checks whether the object is transient (not attached to BM).
        Returns:
        true if the object is transient, false otherwise.