Sha256: 6b79cffc67af9bd64ee784e5ca8a9477265880bb4382406ad1177d3a09c65e22

Contents?: true

Size: 665 Bytes

Versions: 3

Compression:

Stored size: 665 Bytes

Contents

#!/usr/bin/env ruby

require 'expressir'
require 'expressir/express_exp/parser'

# This file is from:
# https://github.com/metanorma/annotated-express/blob/master/data/resources/action_schema/action_schema.exp
file = 'action_schema.exp'

# repo = Expressir::ExpressExp::Parser.from_exp(file)
# schema = repo.schemas.find{|schema| schema.id == "support_resource_schema"}

repo = Expressir::ExpressExp::Parser.from_exp(file)
schema = repo.schemas.find{|schema| schema.id == "action_schema"}
entity = schema.entities.find{|entity| entity.id == "action_directive_relationship"}
where = entity.where.find{|where| where.id == "WR1"}

puts where.inspect

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
expressir-0.2.6 demo.rb
expressir-0.2.5-x64-mingw32 demo.rb
expressir-0.2.4-x64-mingw32 demo.rb