Class: SiSU_Param::Parameters::MdDefault

Inherits:
Object
  • Object
show all
Defined in:
lib/sisu/dp.rb

Instance Method Summary collapse

Instance Method Details

#allObject



150
151
152
153
154
155
156
157
158
159
# File 'lib/sisu/dp.rb', line 150

def all
  s=nil
  if @author
    #puts assignment(@author)
    s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
    ? ("Copyright (C) #{$1} #{@author}")
    : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
  end
  s
end

#assignment(author) ⇒ Object



145
146
147
148
149
# File 'lib/sisu/dp.rb', line 145

def assignment(author)
  'copyright not explicitly stated, ' \
  + 'program "assigning" copyright to author: ' \
  + author
end


173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
# File 'lib/sisu/dp.rb', line 173

def copyright
  def all
    s=nil
    if @author
      s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
      ? ("Copyright (C) #{$1} #{@author}")
      : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
    end
    s
  end
  def text
    all
  end
  self
end


160
161
162
163
164
165
166
167
168
169
# File 'lib/sisu/dp.rb', line 160

def copyright_and_license
  s=nil
  if @author
    #puts assignment(@author)
    s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
    ? ("Copyright (C) #{$1} #{@author}")
    : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
  end
  s
end

#rights(author, date) ⇒ Object



143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
# File 'lib/sisu/dp.rb', line 143

def rights(author,date)
  @author,@date=author,date
  def assignment(author)
    'copyright not explicitly stated, ' \
    + 'program "assigning" copyright to author: ' \
    + author
  end
  def all
    s=nil
    if @author
      #puts assignment(@author)
      s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
      ? ("Copyright (C) #{$1} #{@author}")
      : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
    end
    s
  end
  def copyright_and_license
    s=nil
    if @author
      #puts assignment(@author)
      s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
      ? ("Copyright (C) #{$1} #{@author}")
      : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
    end
    s
  end
  def text
    all
  end
  def copyright
    def all
      s=nil
      if @author
        s ||=((@date =~/((?:1[4-9]|2[01])\d{2})/ ) \
        ? ("Copyright (C) #{$1} #{@author}")
        : ('Copyright (C)' + @author))                     #matches years 1400 through 21\d\d
      end
      s
    end
    def text
      all
    end
    self
  end
  self
end

#textObject



170
171
172
# File 'lib/sisu/dp.rb', line 170

def text
  all
end