[JBoss JIRA] (FORGE-2098) Being able to create a new JPA converter
by Antonio Goncalves (JIRA)
Antonio Goncalves created FORGE-2098:
----------------------------------------
Summary: Being able to create a new JPA converter
Key: FORGE-2098
URL: https://issues.jboss.org/browse/FORGE-2098
Project: Forge
Issue Type: Sub-task
Components: Java EE
Affects Versions: 2.12.1.Final
Reporter: Antonio Goncalves
It would be good to be able to create a new JPA converter with just the following command :
{code}
jpa-new-converter --name CreditCardConverter --fromAttribute CreditCard --toColumn String
{code}
This will generate the following code :
{code}
@Converter(autoApply = true)
public class CreditCardConverter implements AttributeConverter<CreditCard, String> {
@Override
public String convertToDatabaseColumn(CreditCard entityAttribute) {
return null;
}
@Override
public CreditCard convertToEntityAttribute(String databaseColumn) {
return null;
}
}
{code}
(!) This command is only available in JPA 2.1
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2091) Being able to create a new Java exception
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-2091?page=com.atlassian.jira.plugin... ]
Antonio Goncalves updated FORGE-2091:
-------------------------------------
Status: Pull Request Sent (was: Open)
Git Pull Request: https://github.com/forge/core/pull/520
> Being able to create a new Java exception
> -----------------------------------------
>
> Key: FORGE-2091
> URL: https://issues.jboss.org/browse/FORGE-2091
> Project: Forge
> Issue Type: Sub-task
> Components: Parsers / File Manipulation
> Affects Versions: 2.12.1.Final
> Reporter: Antonio Goncalves
> Assignee: Antonio Goncalves
> Fix For: 2.x Future
>
>
> It would be good to have a command to generate a new Java exception. A simple command such as :
> {code}
> java-new-exception --named MyException
> {code}
> Would generate :
> {code}
> public class MyException extends RuntimeException {
> public MyException() {
> super();
> }
> public MyException(String message) {
> super(message);
> }
> }
> {code}
> Another attribute would allow to extends from whatever exception we want. So something like :
> {code}
> java-new-exception --named MyException --inherits MyOtherException
> {code}
> {code}
> public class MyException extends MyOtherException {
> public MyException() {
> super();
> }
> public MyException(String message) {
> super(message);
> }
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2091) Being able to create a new Java exception
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-2091?page=com.atlassian.jira.plugin... ]
Antonio Goncalves reassigned FORGE-2091:
----------------------------------------
Assignee: Antonio Goncalves
> Being able to create a new Java exception
> -----------------------------------------
>
> Key: FORGE-2091
> URL: https://issues.jboss.org/browse/FORGE-2091
> Project: Forge
> Issue Type: Sub-task
> Components: Parsers / File Manipulation
> Affects Versions: 2.12.1.Final
> Reporter: Antonio Goncalves
> Assignee: Antonio Goncalves
> Fix For: 2.x Future
>
>
> It would be good to have a command to generate a new Java exception. A simple command such as :
> {code}
> java-new-exception --named MyException
> {code}
> Would generate :
> {code}
> public class MyException extends RuntimeException {
> public MyException() {
> super();
> }
> public MyException(String message) {
> super(message);
> }
> }
> {code}
> Another attribute would allow to extends from whatever exception we want. So something like :
> {code}
> java-new-exception --named MyException --inherits MyOtherException
> {code}
> {code}
> public class MyException extends MyOtherException {
> public MyException() {
> super();
> }
> public MyException(String message) {
> super(message);
> }
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (ROASTER-41) Being able to add constructors
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/ROASTER-41?page=com.atlassian.jira.plugin... ]
George Gastaldi closed ROASTER-41.
----------------------------------
> Being able to add constructors
> ------------------------------
>
> Key: ROASTER-41
> URL: https://issues.jboss.org/browse/ROASTER-41
> Project: Roaster
> Issue Type: Feature Request
> Components: API
> Affects Versions: 2.8.2.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> At the moment there is no easy way to add a constructor. {{JavaClassSource}} has an API to add methods, fields, annotation... but no constructor. The closest to create a constructor would be :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addMethod().setPublic().setName("MyException").setBody("super();");
> {code}
> The method returns void and setting the name of the method is useless. It would be better to have something like :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addConstructor().setPublic().setBody("super();");
> javaClassSource.addConstructor().setPublic().setParameters("String message").setBody("super(message);");
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (ROASTER-41) Being able to add constructors
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/ROASTER-41?page=com.atlassian.jira.plugin... ]
Antonio Goncalves commented on ROASTER-41:
------------------------------------------
There is no {{addConstructor}} method in Roaster as it treats it as a method. Instead you should use {{setConstructor(true)}} :
{code}
javaClassSource.addMethod().setPublic().setConstructor(true).setBody("super();");
javaClassSource.addMethod().setPublic().setConstructor(true).setParameters("String message").setBody("super(message);");
{code}
> Being able to add constructors
> ------------------------------
>
> Key: ROASTER-41
> URL: https://issues.jboss.org/browse/ROASTER-41
> Project: Roaster
> Issue Type: Feature Request
> Components: API
> Affects Versions: 2.8.2.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> At the moment there is no easy way to add a constructor. {{JavaClassSource}} has an API to add methods, fields, annotation... but no constructor. The closest to create a constructor would be :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addMethod().setPublic().setName("MyException").setBody("super();");
> {code}
> The method returns void and setting the name of the method is useless. It would be better to have something like :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addConstructor().setPublic().setBody("super();");
> javaClassSource.addConstructor().setPublic().setParameters("String message").setBody("super(message);");
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (ROASTER-41) Being able to add constructors
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/ROASTER-41?page=com.atlassian.jira.plugin... ]
Antonio Goncalves resolved ROASTER-41.
--------------------------------------
Resolution: Won't Fix
> Being able to add constructors
> ------------------------------
>
> Key: ROASTER-41
> URL: https://issues.jboss.org/browse/ROASTER-41
> Project: Roaster
> Issue Type: Feature Request
> Components: API
> Affects Versions: 2.8.2.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> At the moment there is no easy way to add a constructor. {{JavaClassSource}} has an API to add methods, fields, annotation... but no constructor. The closest to create a constructor would be :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addMethod().setPublic().setName("MyException").setBody("super();");
> {code}
> The method returns void and setting the name of the method is useless. It would be better to have something like :
> {code}
> javaClassSource.setName("MyException").setSuperType(Exception.class);
> javaClassSource.addConstructor().setPublic().setBody("super();");
> javaClassSource.addConstructor().setPublic().setParameters("String message").setBody("super(message);");
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2066) In jta-setup version should be renamed to jtaVersion
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-2066?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-2066:
-----------------------------------
Status: Closed (was: Pull Request Sent)
Fix Version/s: 2.12.2.Final
(was: 2.x Future)
Resolution: Done
> In jta-setup version should be renamed to jtaVersion
> ----------------------------------------------------
>
> Key: FORGE-2066
> URL: https://issues.jboss.org/browse/FORGE-2066
> Project: Forge
> Issue Type: Sub-task
> Components: Java EE
> Affects Versions: 2.12.0.Final
> Reporter: Antonio Goncalves
> Assignee: Antonio Goncalves
> Fix For: 2.12.2.Final
>
>
> In all the {{setup}} commands, the {{version}} is always prefixed by the specification, except in JTA :
> {code}
> jpa-setup --jpaVersion
> cdi-setup --cdiVersion
> websocket-setup --webSocketVersion
> ejb-setup --ejbVersion
> faces-setup --facesVersion
> jms-setup --jmsVersion
> jstl-setup --jstlVersion
> servlet-setup --servletVersion
> rest-setup --jaxrsVersion
> soap-setup --jaxwsVersion
> {code}
> JTA uses :
> {code}
> jta-setup --version
> {code}
> And should be renamed
> {code}
> jta-setup --jtaVersion
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2078) Being able to create a new CDI decorator
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-2078?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-2078:
-----------------------------------
Status: Closed (was: Pull Request Sent)
Fix Version/s: 2.12.2.Final
(was: 2.x Future)
Resolution: Done
Thanks!
> Being able to create a new CDI decorator
> ----------------------------------------
>
> Key: FORGE-2078
> URL: https://issues.jboss.org/browse/FORGE-2078
> Project: Forge
> Issue Type: Sub-task
> Components: Java EE
> Affects Versions: 2.12.1.Final
> Reporter: Antonio Goncalves
> Assignee: Antonio Goncalves
> Fix For: 2.12.2.Final
>
>
> It would be good to have a command to generate a CDI decorator. A simple command such as :
> {code}
> cdi-new-decorator --named LargeTransactionDecorator --delegate Account
> {code}
> Would generate :
> {code}
> @Decorator
> public abstract class LargeTransactionDecorator implements Account {
> @Inject @Delegate Account delegate;
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2068) When creating a new field, updating toString should be optional
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-2068?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-2068:
-----------------------------------
Status: Closed (was: Pull Request Sent)
Fix Version/s: 2.12.2.Final
(was: 2.x Future)
Resolution: Done
> When creating a new field, updating toString should be optional
> ---------------------------------------------------------------
>
> Key: FORGE-2068
> URL: https://issues.jboss.org/browse/FORGE-2068
> Project: Forge
> Issue Type: Sub-task
> Components: Java EE
> Affects Versions: 2.12.0.Final
> Reporter: Antonio Goncalves
> Assignee: Antonio Goncalves
> Fix For: 2.12.2.Final
>
>
> Today, when we create a new field to a Java class (or CDI bean...), the field is automatically added to the {{toString}} method. It would be good to have the option not to update it, by adding a {{--updateToString}} boolean parameter.
> The following command create a class, adds two fields, one updating the toString, the other no :
> {code}
> java-new-class --named MyClass
> java-new-field --named defaultUpdatesToString
> java-new-field --named doesNotUpdateToString --updateToString false
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months
[JBoss JIRA] (FORGE-2097) Occassionally some files in AngularJS scaffold are created in the wrong directory
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-2097?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-2097:
-----------------------------------
Fix Version/s: 2.x Future
> Occassionally some files in AngularJS scaffold are created in the wrong directory
> ---------------------------------------------------------------------------------
>
> Key: FORGE-2097
> URL: https://issues.jboss.org/browse/FORGE-2097
> Project: Forge
> Issue Type: Bug
> Affects Versions: 2.12.1.Final
> Reporter: Vineet Reynolds
> Fix For: 2.x Future
>
>
> When I select AngularJS as the scaffold provider, and type in {{/admin}} as the web root and proceed to create a scaffold for TicketMonster, sometimes, some of the files are created in directories named {{src/main/webapp/a}}, {{src/main/webapp/adm}} etc. instead of {{src/main/webapp/admin}}.
> This is not always reproducible. It seems to depend on the order in which the inputs are entered, and maybe even the speed with which they are entered.
> Leaving the component as blank for now, since this could be either in the AngularJS addon, or in the UI-Eclipse addon.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
9 years, 6 months