Package biana :: Package BianaObjects :: Module ExternalEntity' :: Class ExternalEntity
[hide private]
[frames] | no frames]

Class ExternalEntity

source code


This general object represents an entry in an external database

It can contain several attributes.

Instance Methods [hide private]
 
__eq__(self, other) source code
 
__init__(self, source_database, type, id=None)
"source_database" is the source database id wbere this entity is described
source code
 
__str__(self)
str(x)
source code
 
add_attribute(self, externalEntityAttribute)
Adds an attribute to this ExternalEntity Object
source code
 
get_attribute(self, attribute_identifier)
Returns a SET with the externalEntityAttribute objects corresponding to the attribute_identifier associated to this externalEntity.
source code
 
get_attributes_dict(self)
Returns a dictionary with all the ExternalEntityAttributes associated to this externalEntity.
source code
 
get_id(self)
Gets the UNIQUE identifier
source code
 
get_source_database(self)
Gets the ExternalDatabase Object where this externalEntity is contained
source code
 
get_type(self)
Gets a string representing the type of this externalEntity
source code
 
set_id(self, id_value) source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__

Static Methods [hide private]
 
get_valid_external_entity_types(biana_database) source code
 
isValidType(type, biana_database) source code
Class Variables [hide private]
  PROMISCUOUS_EXTERNAL_ENTITY_TYPES_DICT = {'SCOPElement': 'PDB'}
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, source_database, type, id=None)
(Constructor)

source code 

"source_database" is the source database id wbere this entity is described

"type" indicates the type of externalEntity.It can be:
                      'protein','gene','protein alignment','cluster','structure, SCOPElement'

"id" is the UNIQUE identifier in the database for this external entity

Overrides: object.__init__

__str__(self)
(Informal representation operator)

source code 

str(x)

Overrides: object.__str__
(inherited documentation)

add_attribute(self, externalEntityAttribute)

source code 

Adds an attribute to this ExternalEntity Object

"externalEntityAttribute": A valid externalEntityAttribute Object. It cannot contain value None as its value

get_attribute(self, attribute_identifier)

source code 

Returns a SET with the externalEntityAttribute objects corresponding to the attribute_identifier associated to this externalEntity.

If the externalEntity object does not contain any attribute of "attribute_identifier" type, it returns an empty list

get_attributes_dict(self)

source code 

Returns a dictionary with all the ExternalEntityAttributes associated to this externalEntity.

Keys correspond to "attribute_identifier" and values to a Set with all external entity objects