1.1 --- a/java/alt2xml-lib-input/src/cz/frantovo/alt2xml/AbstractAlt2XmlReader.java Wed Sep 03 19:48:42 2014 +0200
1.2 +++ b/java/alt2xml-lib-input/src/cz/frantovo/alt2xml/AbstractAlt2XmlReader.java Wed Sep 03 19:49:53 2014 +0200
1.3 @@ -37,6 +37,7 @@
1.4 */
1.5 public abstract class AbstractAlt2XmlReader implements XMLReader {
1.6
1.7 + private static final String PROPERTY_BASE_URL = "https://alt2xml.globalcode.info/sax-property/";
1.8 protected ContentHandler contentHandler;
1.9 protected ErrorHandler errorHandler;
1.10 protected DTDHandler dtdHandler;
1.11 @@ -69,6 +70,17 @@
1.12 features.put(name, value);
1.13 }
1.14
1.15 + /**
1.16 + *
1.17 + * @param readerId should be [a-z0-9] and same as specific part of the module/project name (e.g.
1.18 + * alt2xml-in-properties → properties)
1.19 + * @param propertyId should be [a-z0-9-] and unique per module/reader
1.20 + * @return URL
1.21 + */
1.22 + protected static String constructPropertyName(String readerId, String propertyId) {
1.23 + return PROPERTY_BASE_URL + readerId + "/" + propertyId;
1.24 + }
1.25 +
1.26 @Override
1.27 public Object getProperty(String name) throws SAXNotRecognizedException, SAXNotSupportedException {
1.28 return properties.get(name);