cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jos Snellings <>
Subject COCOON3-99: cross-cultural issue
Date Thu, 10 May 2012 07:54:52 GMT
Dear cocooners,

COCOON3-99 is about applying a user configuration to FopFactory in
To pass the location of the configuration file in a nice and portable way,
it is addressed in the jar:
configurationUrl = this.getClass().getResource("/COB-INF/" +

Fine, but I am still not satisfied. I would like to locate the font file as
well in the block.
FOP however, expects <font-base>, the path relative to the configuration
file to be a real directory.

As we can see from an example fragment from

     baseURI = new URI(base);
     String scheme = baseURI.getScheme();
     boolean directoryExists = true;
     if ("file".equals(scheme)) {
                    dir = FileUtils.toFile(baseURI.toURL());
                    directoryExists = dir.isDirectory();
     if (scheme == null || !directoryExists) {
                    String message = "base " + base + " is not a valid
                    if (throwExceptions) {
                        throw new MalformedURLException(message);

(this is just an example, FO is coded to read resources from expanded

What do we do?
- live in an imperfect world?
- submit patch to FOP, but to be consistent, maintenance in more places is
- cross-post this mail to FO?

I should deliver a war to a party without me having server access. I can
hear them complain when I tell that there is some maintenance necessary.

Kind regards,

The doctrine of human equality reposes on this: that there is no man
really clever who has not found that he is stupid.
        -- Gilbert K. Chesterson

View raw message