Class: Bibliografia::Edoc
- Inherits:
-
Bibliografia
- Object
- Bibliografia
- Bibliografia::Edoc
- Defined in:
- lib/Bibliografia/Bibliografia.rb
Instance Attribute Summary collapse
-
#edicion ⇒ Object
Returns the value of attribute edicion.
-
#editor ⇒ Object
Returns the value of attribute editor.
-
#fechacceso ⇒ Object
Returns the value of attribute fechacceso.
-
#lpublicacion ⇒ Object
Returns the value of attribute lpublicacion.
-
#source ⇒ Object
Returns the value of attribute source.
-
#tipo_medio ⇒ Object
Returns the value of attribute tipo_medio.
Attributes inherited from Bibliografia
#autor, #fecha_publicacion, #titulo
Instance Method Summary collapse
- #access(text, options = {}) ⇒ Object
- #author(text, options = {}) ⇒ Object
- #date(text, options = {}) ⇒ Object
- #edition(text, options = {}) ⇒ Object
- #fuente(text, options = {}) ⇒ Object
-
#initialize(titulo, &bloque) ⇒ Edoc
constructor
A new instance of Edoc.
- #media(text, options = {}) ⇒ Object
- #place(text, options = {}) ⇒ Object
- #the_editor(text, options = {}) ⇒ Object
- #title(text, options = {}) ⇒ Object
- #to_s ⇒ Object
Methods inherited from Bibliografia
Constructor Details
#initialize(titulo, &bloque) ⇒ Edoc
Returns a new instance of Edoc.
225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 |
# File 'lib/Bibliografia/Bibliografia.rb', line 225 def initialize(titulo, &bloque) @autor = [] @fecha_publicacion = [] @titulo = titulo @edicion = [] @tipo_medio = [] @lpublicacion = [] @editor = [] @source = [] @fechacceso = [] if block_given? if bloque.arity == 1 yield self else instance_eval &bloque end end end |
Instance Attribute Details
#edicion ⇒ Object
Returns the value of attribute edicion.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def edicion @edicion end |
#editor ⇒ Object
Returns the value of attribute editor.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def editor @editor end |
#fechacceso ⇒ Object
Returns the value of attribute fechacceso.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def fechacceso @fechacceso end |
#lpublicacion ⇒ Object
Returns the value of attribute lpublicacion.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def lpublicacion @lpublicacion end |
#source ⇒ Object
Returns the value of attribute source.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def source @source end |
#tipo_medio ⇒ Object
Returns the value of attribute tipo_medio.
224 225 226 |
# File 'lib/Bibliografia/Bibliografia.rb', line 224 def tipo_medio @tipo_medio end |
Instance Method Details
#access(text, options = {}) ⇒ Object
282 283 284 285 286 |
# File 'lib/Bibliografia/Bibliografia.rb', line 282 def access(text, = {}) access = text access << " (#{[:a_access]})" if [:a_access] fechacceso << access end |
#author(text, options = {}) ⇒ Object
245 246 247 248 249 |
# File 'lib/Bibliografia/Bibliografia.rb', line 245 def (text, = {}) = text << " (#{[:a_total]})" if [:a_total] autor << end |
#date(text, options = {}) ⇒ Object
251 252 253 254 255 256 |
# File 'lib/Bibliografia/Bibliografia.rb', line 251 def date(text, = {}) date= text date << " (#{[:a_date]})" if [:a_date] fecha_publicacion << date end |
#edition(text, options = {}) ⇒ Object
264 265 266 267 268 |
# File 'lib/Bibliografia/Bibliografia.rb', line 264 def edition(text, = {}) edition = text edition << " (#{[:n_editions]})" if [:n_editions] edicion << edition end |
#fuente(text, options = {}) ⇒ Object
288 289 290 291 292 |
# File 'lib/Bibliografia/Bibliografia.rb', line 288 def fuente(text, = {}) fuente = text fuente<< " (#{[:a_fuente]})" if [:a_fuente] source << fuente end |
#media(text, options = {}) ⇒ Object
294 295 296 297 298 |
# File 'lib/Bibliografia/Bibliografia.rb', line 294 def media(text, = {}) media = text media<< " (#{[:a_media]})" if [:a_media] tipo_medio << media end |
#place(text, options = {}) ⇒ Object
270 271 272 273 274 |
# File 'lib/Bibliografia/Bibliografia.rb', line 270 def place(text, = {}) place = text place << " (#{[:a_place]})" if [:a_place] lpublicacion << place end |
#the_editor(text, options = {}) ⇒ Object
276 277 278 279 280 |
# File 'lib/Bibliografia/Bibliografia.rb', line 276 def the_editor(text, = {}) the_editor = text the_editor << " (#{[:a_editeur]})" if [:a_editeur] editor << the_editor end |
#title(text, options = {}) ⇒ Object
258 259 260 261 262 |
# File 'lib/Bibliografia/Bibliografia.rb', line 258 def title(text, = {}) title= text title << " (#{[:a_title]})" if [:a_title] titulo << title end |
#to_s ⇒ Object
300 301 302 303 304 305 306 |
# File 'lib/Bibliografia/Bibliografia.rb', line 300 def to_s() salida= titulo salida << ", #{autor.join(', ')}, #{fecha_publicacion.join(', ')}, #{edicion.join(', ')}, #{tipo_medio.join(', ')}, #{lpublicacion.join(', ')}, #{editor.join(', ')}, #{source.join(', ')}, #{fechacceso.join(', ')}\n\n" salida end |