xtuml/meta.py
def clone(self, instance):
        '''
        Create a shallow clone of an *instance*.
        
        **Note:** the clone and the original instance **does not** have to be
        part of the same metaclass. 
        '''
        args = list()
        for name, _ in get_metaclass(instance).attributes:
            value = getattr(instance, name)
            args.append(value)
            
        return self.new(*args)
def clone(self, instance):
        '''
        Create a shallow clone of an *instance*.
        
        **Note:** the clone and the original instance **does not** have to be
        part of the same metaclass. 
        '''
        args = list()
        for name, _ in get_metaclass(instance).attributes:
            value = getattr(instance, name)
            args.append(value)
            
        return self.new(*args)
def clone ( self , instance ) : args = list ( ) for name , _ in get_metaclass ( instance ) . attributes : value = getattr ( instance , name ) args . append ( value ) return self . new ( * args )
Create a shallow clone of an *instance*.
        
        **Note:** the clone and the original instance **does not** have to be
        part of the same metaclass.
Create a shallow clone of an * instance * . ** Note : ** the clone and the original instance ** does not ** have to be part of the same metaclass .