Hi, I'm new to JBoss Seam. I'd like to know how do I instantiate a class without a no-arg constructor in JBoss Seam.
I have to instantiate JsonPrimitive (from Google Gson framework) that has just constructors which receive arguments.
How the regular code would be:
import com.google.gson.JsonPrimitive;
...
JsonPrimitive jsonPrimitive = new JsonPrimitive(myobject.toString())
Trying to transport the code to Seam:
import com.google.gson.JsonPrimitive;
..
@In(create=true)
JsonPrimitive jsonPrimitive
But this kind of thing in Seam(shown above) will not help me. I have to pass an argument in the constructor to instantiate the class.
How could I tell Seam to use an argument in the constructor when instantiating an object to be injected?
Thanks!