None
SWISS::CCalt_prod.pm
SWISS::CCalt_prod represents a comment on the topic '\s-1ALTERNATIVE\s0 \s-1PRODUCTS\s0' within a Swiss-Prot or TrEMBL entry as specified in the user manual http://www.expasy.org/sprot/userman.html . Comments on other topics are stored in other types of objects, such as \s-1SWISS::CC\s0 (see SWISS::CCs for more information).
Collectively, comments of all types are stored within a SWISS::CCs container object.
Code example:
This example is given to illustrate the internal construction of an CCalt_prod object. However, for most purposes it should be possible to use the convenience methods provided (e.g. the add, delete, get and set methods doocumented below) instead of constructing the section manually. The use of the convenience methods is also recommended to ensure the structual integrity of the CCalt_prod object.
## Create a new named isoform my %thisFormHash; ## give this some properties # some properties are single data values $thisFormHash{"Name"} = "This"; # some properties are lists of values push @{$thisFormHash{"Synonyms"}}, "That"; push @{$thisFormHash{"Synonyms"}}, "The Other"; push @{$thisFormHash{"IsoId"}}, "P00000-01"; push @{$thisFormHash{"IsoId"}}, "P00000-02"; push @{$thisFormHash{"Sequence"}}, "VSP_000001"; push @{$thisFormHash{"Sequence"}}, "VSP_000002"; $thisFormHash{"Notes"} = "This local note"; ## put this form onto a list of all forms created by one type of event my @newFormsList; push @newFormsList, \%thisFormHash; ## put this list into a hash describing all characteristics of this event my %eventHash; $eventHash{"FormsList"} = \@newFormsList; ## set other values of this event $eventHash{"Comment"} = "This Comment"; ## put the description of this event into a hash descrinbing all events my %eventsHash; $eventsHash{"Alternative splicing"} = \%eventHash; ## put a reference to this hash into the CCalt_products object my $hashRef; $hashRef = \%eventsHash; my $newCC = SWISS::CCalt_prod; $newCC->setEvents($hashRef); $newCC->toString();
More simply, using the convenience methods addComment and addForm:
@synonyms = ("That", "The other"); @isoIds = ("P00000-1", "P00000-2"); @featIds = ("VSP_00001", "VSP_00002"); my $newCC = SWISS::CCalt_prod; $newCC -> addComment("Alternative splicing", "This comment"); $newCC -> addForm("Alternative splicing", "This", \@synonyms, \@isoIds, \@featIds, "This local note"); print $newCC -> toString();
Output from both approaches:
CC -!- ALTERNATIVE PRODUCTS: CC Event=Alternative splicing; Named isoforms=1; CC Comment=This comment. CC Name=This; Synonyms=That, The other; CC IsoId=P00000-1, P00000-2; Sequence=VSP_00001, VSP_00002; CC Note=This local note.
Example of adding evidence tags to a synonym:
$CC -> addEvidenceTag('\s-1EP8\s0', \*(L"Alternative splicing\*(R", \*(L"Synonyms\*(R", \*(L"\s-1VI\s0\*(R", \*(L"B\*(R");
to add the tag '\s-1EP8\s0' to synonym B of isoform \s-1VI\s0, produced by alternative splicing
Handling mutliple events:
With the release of UniProt 8.0, the format of the \s-1CC\s0 \s-1ALTERNATIVE\s0 \s-1PRODUCTS\s0 blocks has changed slightly. In particular, isoforms are no longer stored according to the events that have generated them, so this:
CC -!- ALTERNATIVE PRODUCTS: CC Event=Alternative splicing; Named isoforms=1; CC Comment=This comment. CC Name=This; Synonyms=That, The other; CC IsoId=P00000-1, P00000-2; Sequence=VSP_00001, VSP_00002; CC Note=This local note. CC Event=Alternative initiation; CC Comment=Another comment.
has become this:
CC -!- ALTERNATIVE PRODUCTS: CC Event=Alternative splicing, Alternative initation; Named isoforms=1; CC Comment=This comment. Another comment; CC Name=This; Synonyms=That, The other; CC IsoId=P00000-1, P00000-2; Sequence=VSP_00001, VSP_00002; CC Note=Produced by alternative splicing. This local note;
The \s-1API\s0 is quite event-centric, reflecting the previous file format (where different content was available according to the event type). To get all isoforms (for whatever events are annotated) under the new format, do:
$CC->keyEvent;
which will return an arbitrary event that can be used a parameter in other methods. Any of the events annotated will function as parameters to retrieve information about assocaticated isoforms: it is not necessary to supply the complete list.
SWISS::BaseClass.pm
The topic of this comment ('\s-1ALTERNATIVE\s0 \s-1PRODUCTS\s0').
Allows the user to insert \*(L"events blocks\*(R" into the CCalt_prod object. Add $tag to the tag list associated with the specified component of a CCalt_prod object. The event and type (of the item to which the tag is to be added, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform to which the tag is being attached); the name of the synonym to which the tag are being attached must also be given if the type is \*(L"Synonyms\*(R". Allows the user to add a form into a given event block. See code example (above) for more details.
Deletes the comment associated with this event.
Deletes an event from this CCalt_prod objects. Deletes $tag from the tag list associated with the specified component of a CCalt_prod object. The event and type (of the item from which the tag is to be deleted, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform from which the tag is being deleted); the name of the synonym from which the tag is being deleted must also be given if the type is \*(L"Synonyms\*(R". Deletes a form associated with a given event.
Extracts one of the events annotated in this entry, which can then be used to retrieve data associated with this event
Returns the comment for this event.
Returns a list of all event names for this CCalt_prod object. Returns a list of the tags attached to the specified component of a CCalt_prod object. The event and type (of the item to which the tag is attached, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform whose tags are being fetched); the name of the synonym whose tags are being fetched must also be given if the type is \*(L"Synonyms\*(R". Returns the tags attached to the specified component of a CCalt_prod object as a string literal. The event and type (of the item to which the tag is attached, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform whose tags are being fetched); the name of the synonym whose tags are being fetched must also be given if the type is \*(L"Synonyms\*(R". Returns a list of all feature IDs associated with this form produced by this event.
Returns a list of all form names for this form produced by this event. Returns a list of all IsoIds for this form produced by this event.
Returns the number of named and identified forms for this event. Returns the local note of this form produced by this event. Returns a list of all synonyms of this form produced by this event. Returns 1 if the specified component of a CCalt_prod object has the specified tag. The event and type (of the item to which the tag is attached, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform whose tags are being fetched); the name of the synonym whose tags are being fetched must also be given if the type is \*(L"Synonyms\*(R". Allows the user to add a global comment for a particular event. Sets the evidence tags of the specified component of a CCalt_prod object to the array pointed to by \@tags. The event and type (of the item to which the tag are to be added, i.e. \*(L"Comment\*(R", \*(L"Name\*(R", \*(L"Note\*(R", or \*(L"Synonyms\*(R") must always be specified: unless the type is \*(L"Comment\*(R", the name must also be specifed (i.e. the contents of the Name field for the isoform to which tags are being attached); the name of the synonym to which tags are being attached must also be given if the type is \*(L"Synonyms\*(R".
Can be used to manually insert a hash representing one event. Use of this method is not recommeded, see code examples for how to use the convenience methods to create a CCalt_prod object. Sets the feature Ids for the named form (associated with the specified event) to the supplied list. Changes the name of the formed named $OldName, associated with this event, to the $newName. Sets the Isoform Ids for the named form (associated with the specified event) to the supplied list. Sets the local note for the named form (associated with the specified event). Sets the synonyms for the named form (associated with the specified event) to the supplied list.
Returns a string representation of this comment.
Hey! The above document had some coding errors, which are explained below:
=back doesn't take any parameters, but you said =back =head1 Methods