Module: Bio::PDB::DataType::Pdb_LString
- Defined in:
- lib/bio/db/pdb/pdb.rb
Overview
module Pdb_String
Class Method Summary collapse
Class Method Details
permalink .[](nn) ⇒ Object
[View source]
111 112 113 114 115 116 117 118 119 120 |
# File 'lib/bio/db/pdb/pdb.rb', line 111 def self.[](nn) m = Module.new m.module_eval %Q{ @@nn = nn def self.new(str) str.to_s.ljust(@@nn)[0, @@nn] end } m end |
permalink .new(str) ⇒ Object
[View source]
121 122 123 |
# File 'lib/bio/db/pdb/pdb.rb', line 121 def self.new(str) String.new(str.to_s) end |