Sha256: df2c01e94fbf565445e2ca04ff0ff3f977ccd794563903b2ca12851a98eeffe2

Contents?: true

Size: 824 Bytes

Versions: 15

Compression:

Stored size: 824 Bytes

Contents

require 'jbuilder'

module ADIWG
  module Mdtranslator
    module Writers
      module MdJson
        module Constraint
          def self.build(use, legal, security)
            Jbuilder.new do |json|
              json.useLimitation(use)
              json.legalConstraint(legal) do |lg|
                json.accessConstraint(lg[:accessCodes])
                json.useConstraint(lg[:useCodes])
                json.otherConstraint(lg[:otherCons])
              end
              json.securityConstraint(security) do |sc|
                json.classification sc[:classCode]
                json.userNote sc[:userNote]
                json.classificationSystem sc[:classSystem]
                json.handlingDescription sc[:handlingDesc]
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
adiwg-mdtranslator-1.4.0 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta14 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta13 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta12 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta11 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta10 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta9 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta8 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta7 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta6 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta5 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta4 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta3 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta2 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb
adiwg-mdtranslator-1.4.0.beta1 lib/adiwg/mdtranslator/writers/mdJson/sections/mdJson_constraint.rb