aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v3dv/dal_doc_objects.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sisu/v3dv/dal_doc_objects.rb')
-rw-r--r--lib/sisu/v3dv/dal_doc_objects.rb54
1 files changed, 27 insertions, 27 deletions
diff --git a/lib/sisu/v3dv/dal_doc_objects.rb b/lib/sisu/v3dv/dal_doc_objects.rb
index c476b0ce..e413993a 100644
--- a/lib/sisu/v3dv/dal_doc_objects.rb
+++ b/lib/sisu/v3dv/dal_doc_objects.rb
@@ -67,11 +67,11 @@ module SiSU_DAL_DocumentStructure
def initialize
@tags={}
@is=@tmp=@digest=nil
- @of='meta'
+ @of=:meta
end
def metadata(tags)
of= @of #String, classification - group
- is= 'meta' #String, classification - specific type
+ is= :meta #String, classification - specific type
tags= tags || ((defined? o.tags) ? o.tags : {}) #String, metadata type/tag
obj= nil
@of,@is,@tags,@obj=of,is,tags,obj
@@ -82,11 +82,11 @@ module SiSU_DAL_DocumentStructure
attr_accessor :obj,:is,:of,:tag,:digest,:tmp
def initialize
@is=@obj=@tag=@digest=@digest=@tmp=nil
- @of='meta'
+ @of=:meta
end
def metadata(h,o=nil)
of= @of #String, classification - group
- is= 'meta' #String, classification - specific type
+ is= :meta #String, classification - specific type
tag= h[:tag] || ((defined? o.tag) ? o.tag : nil) #String, metadata type/tag
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
tmp= h[:tmp] || ((defined? o.tmp) ? o.tmp : nil) #available for processing, empty after use
@@ -98,7 +98,7 @@ module SiSU_DAL_DocumentStructure
class ObjectHeading
attr_accessor :obj,:is,:tags,:of,:lv,:ln,:toc_,:name,:idx,:ocn,:odv,:osp,:node,:parent,:ocn_,:note_,:autonum_,:digest,:tmp
def initialize
- @of='para'
+ @of=:para
@is=@obj=@lv=@ln=@toc_=@name=@idx=@size=@ocn=@odv=@osp=@node=@parent=@ocn_=@note_=@autonum_=@digest=@tmp=nil
@tags=[]
end
@@ -135,7 +135,7 @@ module SiSU_DAL_DocumentStructure
h[:lv]=heading_lv(h[:ln])
end
of= @of #String, classification - group
- is= 'heading' #String, classification - specific type
+ is= :heading #String, classification - specific type
name= h[:name] || ((defined? o.name) ? o.name : nil) #String, named object?
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
@@ -162,20 +162,20 @@ module SiSU_DAL_DocumentStructure
end
def heading_insert(h,o=nil)
heading(h,o=nil)
- @is= 'heading_insert' #String, classification - specific type
+ @is= :heading_insert #String, classification - specific type
self
end
end
class ObjectPara
attr_accessor :obj,:is,:tags,:of,:name,:idx,:bullet_,:indent,:hang,:ocn,:odv,:osp,:parent,:note_,:image_,:ocn_,:digest,:tmp
def initialize
- @of='para'
+ @of=:para
@is=@obj=@name=@idx=@bullet_=@indent=@hang=@size=@ocn=@odv=@osp=@parent=@note_=@image_=@ocn_=@digest=@tmp=nil
@tags=[]
end
def paragraph(h,o=nil)
of= @of #String, classification - group
- is= 'para' #String, classification - specific type
+ is= :para #String, classification - specific type
name= h[:name] || ((defined? o.name) ? o.name : nil) #String, named object?
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
@@ -199,7 +199,7 @@ module SiSU_DAL_DocumentStructure
end
def docinfo(h,o=nil)
of= @of #String, classification - group
- is= 'docinfo' #String, classification - specific type
+ is= :docinfo #String, classification - specific type
name= h[:name] || ((defined? o.name) ? o.name : nil) #String, named object?
tags= h[:tags] || ((defined? o.tags) ? o.tags : nil) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
@@ -225,13 +225,13 @@ module SiSU_DAL_DocumentStructure
class ObjectBlockTxt
attr_accessor :obj,:is,:of,:tags,:idx,:ocn,:odv,:osp,:parent,:note_,:number_,:ocn_,:digest,:tmp
def initialize
- @of='block'
+ @of=:block
@is=@obj=@idx=@ocn=@odv=@osp=@parent=@note_=@number_=@ocn_=@digest=@tmp=nil
@tags=[]
end
def code(h,o=nil)
of= @of #String, classification - group #alt 'code'
- is= 'code' #String, classification - specific type
+ is= :code #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
@@ -251,7 +251,7 @@ module SiSU_DAL_DocumentStructure
end
def block(h,o=nil)
of= @of #String, classification - group
- is= 'block' #String, classification - specific type
+ is= :block #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
@@ -270,7 +270,7 @@ module SiSU_DAL_DocumentStructure
end
def group(h,o=nil)
of= @of #String, classification - group
- is= 'group' #String, classification - specific type
+ is= :group #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
@@ -289,7 +289,7 @@ module SiSU_DAL_DocumentStructure
end
def alt(h,o=nil) #see block
of= @of #String, classification - group
- is= 'alt' #String, classification - specific type
+ is= :alt #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
@@ -308,7 +308,7 @@ module SiSU_DAL_DocumentStructure
end
def verse(h,o=nil) #part of poem decide how you deal with this
of= @of #String, classification - group
- is= 'verse' #String, classification - specific type
+ is= :verse #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
@@ -329,13 +329,13 @@ module SiSU_DAL_DocumentStructure
class ObjectTable
attr_accessor :obj,:is,:of,:lv,:tags,:name,:idx,:indent,:hang,:size,:ocn,:number,:head_,:cols,:widths,:odv,:osp,:parent,:note_,:ocn_,:digest,:tmp
def initialize
- @of='block'
+ @of=:block
@is=@obj=@lv=@name=@idx=@indent=@hang=@size=@ocn,@number,@head_,@cols,@widths=@odv=@osp=@parent=@note_=@ocn_=@digest=@tmp=nil
@tags=[]
end
def table(h,o=nil)
of= @of #String, classification - group
- is= 'table' #String, classification - specific type
+ is= :table #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
cols= h[:cols] || ((defined? o.cols) ? o.cols : nil)
widths= h[:widths] || ((defined? o.widths) ? o.widths : nil)
@@ -359,13 +359,13 @@ module SiSU_DAL_DocumentStructure
class ObjectImage
attr_accessor :obj,:is,:of,:lv,:idx,:size,:ocn,:parent,:note_,:ocn_,:digest,:tmp
def initialize
- @of='image'
+ @of=:image
@is=@obj=@lv=@idx=@size=@ocn=@parent=@note_=@ocn_=@tmp=@digest=nil
@tags=[]
end
def image(h,o=nil) #not yet used, and what of a paragraph containing several images, consider
of= @of #String, classification - group
- is= 'image' #String, classification - specific type
+ is= :image #String, classification - specific type
tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
size= h[:size] || ((defined? o.size) ? o.size : nil)
@@ -387,12 +387,12 @@ module SiSU_DAL_DocumentStructure
class ObjectStructure
attr_accessor :obj,:tag,:node,:lv,:ln,:status,:is,:of,:tmp
def initialize
- @of='structure'
+ @of=:structure
@is=@obj=@node=@lv=@ln=@status=@tmp=nil
end
def xml_dom(h,o=nil)
of= @of #String, classification - group
- is= 'xml_dom' #String, classification - specific type
+ is= :xml_dom #String, classification - specific type
obj= h[:obj] || ((defined? o.obj) ? o.obj : '') #String, text content
lv= h[:lv] || ((defined? o.lv) ? o.lv : nil) #Alpha-numeric, document structure as used in markup, A-C then 1-6
ln= h[:ln] || ((defined? o.ln) ? o.ln : nil) #Integer, document structure level, for convenience in processing 1-9
@@ -406,12 +406,12 @@ module SiSU_DAL_DocumentStructure
class ObjectComment
attr_accessor :obj,:is,:of,:tmp
def initialize
- @of='comment'
+ @of=:comment
@is=@obj=@tmp=nil
end
def comment(h,o=nil)
of= @of #String, classification - group
- is= 'comment' #String, classification - specific type
+ is= :comment #String, classification - specific type
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
tmp= h[:tmp] || ((defined? o.tmp) ? o.tmp : nil) #available for processing, empty after use
@of,@is,@obj,@tmp=of,is,obj,tmp
@@ -421,12 +421,12 @@ module SiSU_DAL_DocumentStructure
class ObjectLayout
attr_accessor :obj,:is,:of,:tmp
def initialize
- @of='layout'
+ @of=:layout
@is=@obj=@tmp=nil
end
def break(h,o=nil) #decide how to deal with, perhaps no obj?
of= @of #String, classification - group
- is= 'break' #String, classification - specific type
+ is= :break #String, classification - specific type
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
tmp= h[:tmp] || ((defined? o.tmp) ? o.tmp : nil) #available for processing, empty after use
@of,@is,@obj,@tmp=of,is,obj,tmp
@@ -434,7 +434,7 @@ module SiSU_DAL_DocumentStructure
end
def insert(h,o=nil) #decide how to deal with, could mimic paragraph?
of= @of #String, classification - group
- is= 'insert' #String, classification - specific type
+ is= :insert #String, classification - specific type
obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
tmp= h[:tmp] || ((defined? o.tmp) ? o.tmp : nil) #available for processing, empty after use
@of,@is,@obj,@tmp=of,is,obj,tmp