Class: RDoc::Fortran95parser::Fortran95Definition
- Inherits:
-
Object
- Object
- RDoc::Fortran95parser::Fortran95Definition
- Defined in:
- lib/rdoc/parsers/parse_f95.rb
Overview
Information of arguments of subroutines and functions in Fortran95
Instance Attribute Summary collapse
-
#arraysuffix ⇒ Object
readonly
Suffix of array.
-
#comment ⇒ Object
Comments.
-
#inivalue ⇒ Object
readonly
Initial Value.
-
#nodoc ⇒ Object
Flag of non documentation.
-
#types ⇒ Object
readonly
Types of variable.
-
#varname ⇒ Object
readonly
Name of variable.
Instance Method Summary collapse
-
#include_attr?(attr) ⇒ Boolean
If attr is included, true is returned.
-
#initialize(varname, types, inivalue, arraysuffix, comment, nodoc = false) ⇒ Fortran95Definition
constructor
A new instance of Fortran95Definition.
- #to_s ⇒ Object
Constructor Details
#initialize(varname, types, inivalue, arraysuffix, comment, nodoc = false) ⇒ Fortran95Definition
Returns a new instance of Fortran95Definition.
1671 1672 1673 1674 1675 1676 1677 1678 1679 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1671 def initialize(varname, types, inivalue, arraysuffix, comment, nodoc=false) @varname = varname @types = types @inivalue = inivalue @arraysuffix = arraysuffix @comment = comment @nodoc = nodoc end |
Instance Attribute Details
#arraysuffix ⇒ Object (readonly)
Suffix of array
1661 1662 1663 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1661 def arraysuffix @arraysuffix end |
#comment ⇒ Object
Comments
1665 1666 1667 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1665 def comment @comment end |
#inivalue ⇒ Object (readonly)
Initial Value
1657 1658 1659 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1657 def inivalue @inivalue end |
#nodoc ⇒ Object
Flag of non documentation
1669 1670 1671 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1669 def nodoc @nodoc end |
#types ⇒ Object (readonly)
Types of variable
1653 1654 1655 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1653 def types @types end |
#varname ⇒ Object (readonly)
Name of variable
1649 1650 1651 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1649 def varname @varname end |
Instance Method Details
#include_attr?(attr) ⇒ Boolean
If attr is included, true is returned
1695 1696 1697 1698 1699 1700 1701 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1695 def include_attr?(attr) return if !attr @types.split(",").each{ |type| return true if type.strip.chomp.upcase == attr.strip.chomp.upcase } return nil end |
#to_s ⇒ Object
1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 |
# File 'lib/rdoc/parsers/parse_f95.rb', line 1681 def to_s return <<-EOF <Fortran95Definition: varname=#{@varname}, types=#{types}, inivalue=#{@inivalue}, arraysuffix=#{@arraysuffix}, nodoc=#{@nodoc}, comment= #{@comment} > EOF end |