Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

130
Views
Apache velocity multiple variables

I am using apache velocity to generate multiple templates, the problem is that in each templates multiple (read many) variables are being used and it becomes very tedious to initialize each and every variable seperately.

Is there a work around this or i have no other option?

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

See there are two work around this thing, the 1st and the best option is that you create a Java Bean class that will contain all your template variables and you can then just initialise separate objects for each and every instance of your template, you just have merge the object with context.

Another way is creating and using a java property file which is not only tedious as you have to create separate property file for each and every time you want to create a new file from your template but also deprecated.

You can read about this more on Apache velocity official documentation.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!