Class: Plurimath::Math::Core
  
  
  
  
  
    - Inherits:
 
    - 
      Object
      
        
          - Object
 
          
            - Plurimath::Math::Core
 
          
        
        show all
      
     
  
  
  
  
  
  
  
  
  
  
    - Defined in:
 
    - lib/plurimath/math/core.rb
 
  
  
 
  
    
      Instance Method Summary
      collapse
    
    
  
  
    Instance Method Details
    
      
  
  
    #class_name  ⇒ Object 
  
  
  
  
    
      
6
7
8 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 6
def class_name
  self.class.name.split("::").last.downcase
end
     | 
  
 
    
      
  
  
    #empty_tag(wrapper_tag)  ⇒ Object 
  
  
  
  
    
      
22
23
24
25
26 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 22
def empty_tag(wrapper_tag)
  r_tag = Utility.ox_element("r", namespace: "m")
  r_tag << (Utility.ox_element("t", namespace: "m") << "​")
  wrapper_tag << r_tag
end
     | 
  
 
    
      
  
  
    #insert_t_tag  ⇒ Object 
  
  
  
  
    
      
10
11
12 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 10
def insert_t_tag
  Array(to_omml_without_math_tag)
end 
     | 
  
 
    
      
  
  
    #nary_attr_value  ⇒ Object 
  
  
  
  
    
      
18
19
20 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 18
def nary_attr_value
  ""
end 
     | 
  
 
    
      
  
  
    #omml_parameter(field, tag_name:, namespace: "m")  ⇒ Object 
  
  
  
  
    
      
28
29
30
31
32
33
34
35
36 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 28
def omml_parameter(field, tag_name: , namespace: "m")
  tag = Utility.ox_element(tag_name, namespace: namespace)
  return empty_tag(tag) unless field
  Utility.update_nodes(
    tag,
    field&.insert_t_tag,
  )
end
     | 
  
 
    
      
  
  
    #tag_name  ⇒ Object 
  
  
  
  
    
      
14
15
16 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 14
def tag_name
  "subsup"
end 
     | 
  
 
    
      
  
  
    
      
38
39
40 
     | 
    
      # File 'lib/plurimath/math/core.rb', line 38
def validate_function_formula
  true
end 
     |