<commit_before>/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.xproclet.xproc;

import com.xmlcalabash.core.XProcException;
import com.xmlcalabash.io.ReadablePipe;
import com.xmlcalabash.io.WritableDocument;
import com.xmlcalabash.model.RuntimeValue;
import com.xmlcalabash.model.Serialization;
import com.xmlcalabash.runtime.XInput;
import com.xmlcalabash.runtime.XPipeline;
import com.xmlcalabash.util.S9apiUtils;
import java.io.IOException;
import java.io.OutputStream;
import java.io.StringReader;
import java.net.URI;
import java.net.URISyntaxException;
import java.net.URL;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.TreeMap;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.xml.transform.sax.SAXSource;
import net.sf.saxon.s9api.Axis;
import net.sf.saxon.s9api.DocumentBuilder;
import net.sf.saxon.s9api.QName;
import net.sf.saxon.s9api.SaxonApiException;
import net.sf.saxon.s9api.XdmItem;
import net.sf.saxon.s9api.XdmNode;
import net.sf.saxon.s9api.XdmNodeKind;
import net.sf.saxon.s9api.XdmSequenceIterator;
import org.restlet.Context;
import org.restlet.Request;
import org.restlet.Response;
import org.restlet.data.CacheDirective;
import org.restlet.data.Form;
import org.restlet.data.MediaType;
import org.restlet.data.Method;
import org.restlet.data.Reference;
import org.restlet.data.Status;
import org.restlet.engine.header.Header;
import org.restlet.representation.OutputRepresentation;
import org.restlet.representation.Representation;
import org.restlet.representation.StringRepresentation;
import org.restlet.util.Series;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.NodeList;
import org.xml.sax.InputSource;

/**
 *
 * @author alex
 */
public class XProcHelper {

   final static String NS = "http://www.atomojo.org/V/XProc/2011/1/0";
   final static String HTTP_NS = "http://www.atomojo.org/V/HTTP/2011/1/0";
   final static QName HTTP_NAME = QName.fromClarkName("{"+HTTP_NS+"}http");
   final static QName HEADER_NAME = QName.fromClarkName("{"+HTTP_NS+"}header");
   final static QName ENTITY_NAME = QName.fromClarkName("{"+HTTP_NS+"}entity");
   final static QName ATTRIBUTE_NAME = QName.fromClarkName("{"+HTTP_NS+"}attribute");
   final static QName STATUS_NAME = QName.fromClarkName("status");
   final static QName NAME_NAME = QName.fromClarkName("name");
   final static QName TYPE_NAME = QName.fromClarkName("type");
   final static QName VALUE_NAME = QName.fromClarkName("value");
   final static QName LAST_MODIFIED_NAME = QName.fromClarkName("last-modified");
   public final static String XPROC_CONFIG_ATTR = "xproc.configuration";
   final static SimpleDateFormat xsdDateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ");
   final static SimpleDateFormat xsdDateFormatWithMilliseconds = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
   
   static class OptionBinding {
      enum Source {
         ATTRIBUTES,
         HEADERS,
         PARAMETERS,
         QUERY,<commit_msg>changed namespace constants<commit_after>/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.xproclet.xproc;

import com.xmlcalabash.core.XProcException;
import com.xmlcalabash.io.ReadablePipe;
import com.xmlcalabash.io.WritableDocument;
import com.xmlcalabash.model.RuntimeValue;
import com.xmlcalabash.model.Serialization;
import com.xmlcalabash.runtime.XInput;
import com.xmlcalabash.runtime.XPipeline;
import com.xmlcalabash.util.S9apiUtils;
import java.io.IOException;
import java.io.OutputStream;
import java.io.StringReader;
import java.net.URI;
import java.net.URISyntaxException;
import java.net.URL;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.TreeMap;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.xml.transform.sax.SAXSource;
import net.sf.saxon.s9api.Axis;
import net.sf.saxon.s9api.DocumentBuilder;
import net.sf.saxon.s9api.QName;
import net.sf.saxon.s9api.SaxonApiException;
import net.sf.saxon.s9api.XdmItem;
import net.sf.saxon.s9api.XdmNode;
import net.sf.saxon.s9api.XdmNodeKind;
import net.sf.saxon.s9api.XdmSequenceIterator;
import org.restlet.Context;
import org.restlet.Request;
import org.restlet.Response;
import org.restlet.data.CacheDirective;
import org.restlet.data.Form;
import org.restlet.data.MediaType;
import org.restlet.data.Method;
import org.restlet.data.Reference;
import org.restlet.data.Status;
import org.restlet.engine.header.Header;
import org.restlet.representation.OutputRepresentation;
import org.restlet.representation.Representation;
import org.restlet.representation.StringRepresentation;
import org.restlet.util.Series;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.NodeList;
import org.xml.sax.InputSource;

/**
 *
 * @author alex
 */
public class XProcHelper {

   final static String NS = "http://www.xproclet.org/V/XProc/";
   final static String HTTP_NS = "http://www.xproclet.org/V/HTTP/";
   final static QName HTTP_NAME = QName.fromClarkName("{"+HTTP_NS+"}http");
   final static QName HEADER_NAME = QName.fromClarkName("{"+HTTP_NS+"}header");
   final static QName ENTITY_NAME = QName.fromClarkName("{"+HTTP_NS+"}entity");
   final static QName ATTRIBUTE_NAME = QName.fromClarkName("{"+HTTP_NS+"}attribute");
   final static QName STATUS_NAME = QName.fromClarkName("status");
   final static QName NAME_NAME = QName.fromClarkName("name");
   final static QName TYPE_NAME = QName.fromClarkName("type");
   final static QName VALUE_NAME = QName.fromClarkName("value");
   final static QName LAST_MODIFIED_NAME = QName.fromClarkName("last-modified");
   public final static String XPROC_CONFIG_ATTR = "xproc.configuration";
   final static SimpleDateFormat xsdDateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ");
   final static SimpleDateFormat xsdDateFormatWithMilliseconds = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
   
   static class OptionBinding {
      enum Source {
         ATTRIBUTES,
         HEADERS,
         PARAMETERS,
         QUERY,
{'fraction_non_alphanumeric': 0.1155403301152289, 'fraction_numerical': 0.005605730302086578, 'mean_word_length': 5.217812197483059, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 20}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5929685', 'n_tokens_mistral': 2213, 'n_tokens_neox': 2168, 'n_words': 413}