Re: Interesting question

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: Interesting question

Per Gunnar Hansø
Glen Mazza wrote:

> --- Miroslav Pukhalsky <[hidden email]>
> wrote:
>
>
>>Hi there!
>>
>>Glen Mazza wrote:
>>
>>>Looks like an Apache Ant task.  Look at the
>>
>>example at
>>
>>>the bottom of [1].
>>>
>>>[1] http://xml.apache.org/fop/anttask.html
>>>
>>>Glen
>>>
>>
>>Thanks, but ANT is out law :(
>>
>>Miroslav
>>
>
>
> That's quite unfortunate, as Ant is an excellent
> productivity tool.  I would try to get your company to
> reconsider.  
>
> Anyway, I think your next step may be to start looking
> at writing your own Java program using JAXP to process
> all those files.  The Embed[1] page on our website
> should be of help.
>
> Glen
>
> [1] http://xml.apache.org/fop/embedding.html
>
Far too late, perhaps, but this gives you a starting block.


Regards,
Per Gunnar Hansø




package no.prokonsult;
import org.apache.fop.apps.Fop;

/*
 * Created on 24.jan.2005
 *
 */

/**
 * @author Per Gunnar Hansø
 *
 */
public class FO2PDF {

  public static void main(String[] args) {
    long start = System.currentTimeMillis();
    for (int i = 0; i < 1; i++) {
      String[] newArgs = { "-fo", "RettmedLop" + i + ".fo", "-pdf", "RettmedLop" + i + ".pdf" };
      Fop.main(newArgs);
    }
    long stop = System.currentTimeMillis();
    System.out.println("Duration: " + (stop - start) + " milliseconds");
  }
}

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Interesting question

Jeremias Maerki
Please note that this is NOT a recommended way to call FOP!!!

Please see the examples on the Embedding page on FOP's website for
recommended ways:
http://xml.apache.org/fop/embedding.html#examples

On 11.05.2005 16:30:40 Per Gunnar Hansø wrote:

> package no.prokonsult;
> import org.apache.fop.apps.Fop;
>
> /*
>  * Created on 24.jan.2005
>  *
>  */
>
> /**
>  * @author Per Gunnar Hansø
>  *
>  */
> public class FO2PDF {
>
>   public static void main(String[] args) {
>     long start = System.currentTimeMillis();
>     for (int i = 0; i < 1; i++) {
>       String[] newArgs = { "-fo", "RettmedLop" + i + ".fo", "-pdf", "RettmedLop" + i + ".pdf" };
>       Fop.main(newArgs);
>     }
>     long stop = System.currentTimeMillis();
>     System.out.println("Duration: " + (stop - start) + " milliseconds");
>   }
> }



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]