def add(self, obj, metadata=None, update=False):
        """
        Add an existing CDSTAR object to the catalog.

        :param obj: A pycdstar.resource.Object instance
        """
        if (obj not in self) or update:
            self[obj.id] = Object.fromdict(
                obj.id,
                dict(
                    metadata=obj.metadata.read() if metadata is None else metadata,
                    bitstreams=[bs._properties for bs in obj.bitstreams]))
            time.sleep(0.1)
            return self.objects[obj.id]
def add ( self , obj , metadata = None , update = False ) : if ( obj not in self ) or update : self [ obj . id ] = Object . fromdict ( obj . id , dict ( metadata = obj . metadata . read ( ) if metadata is None else metadata , bitstreams = [ bs . _properties for bs in obj . bitstreams ] ) ) time . sleep ( 0.1 ) return self . objects [ obj . id ]
Add an existing CDSTAR object to the catalog.

        :param obj: A pycdstar.resource.Object instance