Bio::T...eldInfo(3pm)

πŸ“¦
version 1.77 Β· 4 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– NAME πŸ’–

okay so this is the perl doc for Bio::Tools::EUtilities::Info::FieldInfo β€” it's the class that stores all your einfo field data, bestie. that's it, that's the whole job. πŸŽ€


✨ VERSION ✨

version 1.77 β€” yes queen, she's on 1.77 πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

#### should not create instance directly; Bio::Tools::EUtilities does this ####

my $info = Bio::Tools::EUtilities->new(-eutil => 'einfo',
                                       -file => 'einfo.xml');
# can also use '-response' (for HTTP::Response objects) or '-fh' (for filehandles)

# print available databases (if data is present)
print join(', ',$info->get_available_databases),"\n";

# get database info
my $db = $info->get_database; # in case you forgot...
my $desc = $info->get_description;
my $nm = $info->get_menu_name;
my $ct = $info->get_record_count;
my $dt = $info->get_last_update;
# EUtilDataI interface methods
my $eutil = $info->eutil;
my $type = $info->type;

# iterate through Field and Link objects
while (my $field = $info->next_Field) {
    print "Field code: ",$field->get_field_code,"\n";
    print "Field name: ",$field->get_field_name,"\n";
    print "Field desc: ",$field->get_field_description,"\n";
    print "DB  : ",$field->get_database,"\n";
    print "Term ct   : ",$field->get_term_count,"\n";
    for my $att (qw(is_date is_singletoken is_hierarchy is_hidden is_numerical)) {
        print "\tField $att\n" if $field->$att;
    }
}

my @fields = $info->get_Fields; # grab them all (useful for grep)

$info->rewind('fields'); # rewinds Field iterator
lowkey important: you do NOT make one of these yourself. Bio::Tools::EUtilities handles that for you, bestie. don't be the main character who instantiates it directly. πŸ™ˆ

🌸 DESCRIPTION 🌸

this class handles the simple field data output (XML) that comes out of einfo. she takes the raw XML and turns it into cute little objects you can actually poke at. it's giving ✨organized✨.

want the tea on einfo itself? the original source says:

http://eutils.ncbi.nlm.nih.gov/entrez/query/static/einfo_help.html

iykyk, go read it 🧚


πŸŽ€ new

  • Title: new
  • Note: * should not be called by end-users *
  • Usage: my $ct = Bio::Tools::EUtilities::Info::FieldInfo;
  • Function: returns new FieldInfo instance
  • Returns: Bio::Tools::EUtilities::Info::FieldInfo instance
  • Args: none (all data added via _add_data, most methods are getters only)
literally not for you, babe. this is a backstage method. πŸ’…

πŸ“ get_term_count

  • Title: get_term_count
  • Usage: my $ct = $field->get_term_count;
  • Function: returns number of terms for field
  • Returns: integer
  • Args: none

🌈 get_field_name

  • Title: get_field_name
  • Usage: my $nm = $field->get_field_name;
  • Function: returns the full name of the field
  • Returns: string
  • Args: none

πŸ¦‹ get_full_name

  • Title: get_full_name
  • Note: alias of get_field_name()
same girl, different name. she's versatile like that. πŸ’–

⭐ get_field_code

  • Title: get_field_code
  • Usage: $field->get_field_code()
  • Function: returns field code (abbreviation) used for queries
  • Returns: string
  • Args: none

🧚 get_field_description

  • Title: get_field_description
  • Usage: $field->get_field_description
  • Function: returns field description
  • Returns: string
  • Args: none
  • Note: alias of get_description()

πŸ’œ is_date

  • Title: is_date
  • Usage: if ($field->is_date) {...}
  • Function: returns true if field contains date information
  • Returns: Boolean
  • Args: none

✨ is_singletoken

  • Title: is_singletoken
  • Usage: if ($field->is_singletoken) {...}
  • Function: returns true if field has single value in docsums
  • Returns: Boolean
  • Args: none

πŸŽ€ is_hierarchy

  • Title: is_hierarchy
  • Usage: if ($field->is_hierarchy) {...}
  • Function: returns true if field contains hierarchal values
  • Returns: Boolean
  • Args: none

πŸ‘‘ is_hidden

  • Title: is_hidden
  • Usage: if ($field->is_hidden) {...}
  • Function: returns true if field is hidden in docsums
  • Returns: Boolean
  • Args: none
she's hidden, not gone. act accordingly. πŸ’€

πŸ”₯ is_numerical

  • Title: is_numerical
  • Usage: if ($field->is_numerical) {...}
  • Function: returns true if field contains a numerical value
  • Returns: Boolean
  • Args: none

🌸 to_string

  • Title: to_string
  • Usage: $foo->to_string()
  • Function: converts current object to string
  • Returns: none
  • Args: (optional) simple data for text formatting
  • Note: Used generally for debugging and for various print methods
the classic "just print it so i can see what's going on" move. iconic for a reason. 🫢

πŸ’Œ FEEDBACK πŸ’Œ

Mailing lists

user feedback is integral to how this module and all the other Bioperl modules grow and evolve. send your comments and suggestions preferably to the Bioperl mailing list β€” your participation is genuinely so appreciated. πŸ₯Ί

bioperl-l@bioperl.org               - General discussion
https://bioperl.org/Support.html    - About the mailing lists

Support

pls pls pls direct your usage questions and support issues to the mailing list:

bioperl-l@bioperl.org

...rather than sliding into the module maintainer's DMs directly, bestie. there are many experienced and reponsive experts on that list who will look at your problem and address it fast. and when you do write in, include a thorough description of the problem with code and data examples if at all possible. no vague "it doesn't work" energy, we're better than that. πŸ’…

Reporting bugs

found a bug? report it to the Bioperl bug tracking system so we can keep track of the bugs and their resolution. bug reports can be submitted via the web:

https://github.com/bioperl/bio-eutilities/issues

🌟 AUTHOR 🌟

Chris Fields <cjfields@bioperl.org>


This software is copyright (c) 2006-2013 by Chris Fields.

This software is available under the same terms as the perl 5 programming language system itself.


and that's the whole page, bestie πŸ’– this one's from perl v5.40.0, dated 2025-01-27, and yeah the header truncated her name all cute like Bio::T...eldInfo(3pm) but you know exactly who she is. slay, go query some fields. βœ¨πŸ¦‹πŸ’…

πŸ“¦ where this page comes from