lib/opener/kaf_to_json.rb
##
# Processes the input KAF document and returns a String containing the JSON
# output.
#
# @param [String] input The input to process.
# @return [String]
#
Processes the input KAF document and returns a String containing the JSON
output.
Processes the input KAF document and returns a String containing the JSON output .
def run(input)
      encoded = Rumoji.encode(input)
      doc = Saxon::XML(encoded)
      xslt = Saxon::XSLT(File.read(xsl))
      decoded = Rumoji.decode(xslt.transform(doc).to_s)
      return decoded
    end
def run ( input ) encoded = Rumoji . encode ( input ) doc = Saxon :: XML ( encoded ) xslt = Saxon :: XSLT ( File . read ( xsl ) ) decoded = Rumoji . decode ( xslt . transform ( doc ) . to_s ) return decoded end
Processes the input KAF document and returns a String containing the JSON
output.
Processes the input KAF document and returns a String containing the JSON output .
None
String
input
input The input to process.
input The input to process .