Related
Gabriel Sanmartin I am creating a REST api where I am returning domain objects as JSON entities. So far I'm creating a controller where for each method I have to annotate it like this: @RequestMapping(value="/entity/{id}", produces = "application/json; charset
Gabriel Sanmartin I am creating a REST api where I am returning domain objects as JSON entities. So far I am creating a controller where I have to annotate each method like this: @RequestMapping(value="/entity/{id}", produces = "application/json; charset=utf-8
Chris Smith If I annotate a class @Transactionallike this : @Transactional
class MyService { ... }
Is this the same as annotating all its methods @Transactional: class MyService {
@Transactional
void myFunction() { ... }
}
There are a few other thing
iceberg When developing new classes/methods for a Java project, sometimes you want people to try out your new code, but don't want to guarantee that it will be backward compatible in future releases. In this case, use something like the @Unstable annotation to
iceberg When developing new classes/methods for a Java project, sometimes you want people to try out your new code, but don't want to guarantee that it will be backward compatible in future releases. In this case, use something like the @Unstable annotation to
iceberg When developing new classes/methods for a Java project, sometimes you want people to try out your new code, but you don't want to guarantee that it will be backward compatible in future releases. In this case, use something like the @Unstable annotatio
iceberg When developing new classes/methods for a Java project, sometimes you want people to try out your new code, but you don't want to guarantee that it will be backward compatible in future releases. In this case, use something like the @Unstable annotatio
Colleze I'm trying to make an ArrayList that handles different GUI components. This class should have methods, some of which won't work for all components, so I've tried using conditional buys and can't seem to solve it that way. Can you point me in the right
Colleze I'm trying to make an ArrayList that handles different GUI components. This class should have methods, some of which won't work for all components, so I've tried using conditional buys and can't seem to solve it that way. Can you point me in the right
Annoirq I have in my model: @Entity
@Where(clause="is_deleted <> '1'")
public class Ad {
In 95% of cases I will use undeleted ads. However, for one method, I need to get all the removed ads. How can I avoid Whereusing this clause in the query? I am using Crit
Annoirq I have in my model: @Entity
@Where(clause="is_deleted <> '1'")
public class Ad {
In 95% of cases I will use undeleted ads. However, for one method, I need to get all the removed ads. How can I avoid Whereusing this clause in the query? I am using Crit
benstpierre: I have a simple question about Hibernate usage. I keep seeing people using JPA annotations in one of two ways, by annotating the fields of the class and also by annotating the get method of the corresponding bean. My question is the following: wit
benstpierre: I have a simple question about Hibernate usage. I keep seeing people using JPA annotations in one of two ways, by annotating the fields of the class and also by annotating the get method of the corresponding bean. My question is the following: wit
Benstpierre : I have a simple question about Hibernate usage. I keep seeing people using JPA annotations in one of two ways, by annotating the fields of the class and also by annotating the get method of the corresponding bean. My question is the following: wi
Raqqa Ok, currently I'm displaying some data on an html page. I have used a jquery ajax call which fetches data from a specific url on spring MVC application and returns the data and then displays the data in a table using javascript. @RequestMapping(value = "
Raqqa Ok, currently I'm displaying some data on an html page. I have used a jquery ajax call which fetches data from a specific url on spring MVC application and returns the data and then displays the data in a table using javascript. @RequestMapping(value = "
Raqqa Ok, currently I'm displaying some data on an html page. I have used a jquery ajax call which fetches data from a specific url on spring MVC application and returns the data and then displays the data in a table using javascript. @RequestMapping(value = "
Raqqa Ok, currently I'm displaying some data on an html page. I have used a jquery ajax call which fetches data from a specific url on spring MVC application and returns the data and then displays the data in a table using javascript. @RequestMapping(value = "
Raqqa Ok, currently I'm displaying some data on an html page. I have used a jquery ajax call which fetches data from a specific url on spring MVC application and returns the data and then displays the data in a table using javascript. @RequestMapping(value = "
Renato Dihani In my application, my service class has stateless methods that only run in method parameters. My problem is that many of the methods call external APIs that require user and application requests. A simple solution is to add these parameters to al
urison Obs: Sure, I can create a validation method and call this method in all other methods. But I'm wondering if it's possible to do something I've been thinking about for a while. I need: I have a class where all my methods should verify that the parameter
Renato Dihani In my application, my service class has stateless methods that only run in method parameters. My problem is that many of the methods call external APIs that require user and application requests. A simple solution is to add these parameters to al
urison Obs: Sure, I can create a validation method and call this method in all other methods. But I'm wondering if it's possible to do something I've been thinking about for a while. I need: I have a class where all my methods should verify that the parameter
urison Obs: Sure, I can create a validation method and call this method in all other methods. But I'm wondering if it's possible to do something I've been thinking about for a while. I need: I have a class where all my methods should verify that the parameter
wesnon What I want is: @RequestMapping("/**")
public @ResponseBody Object getSomething(@RequestBody DataRequest req) {
// return anything can be transformed into json
}
If I use a concrete return type on this method it works. E.g: @RequestMapping("/**")
p
wesnon What I want is: @RequestMapping("/**")
public @ResponseBody Object getSomething(@RequestBody DataRequest req) {
// return anything can be transformed into json
}
If I use a concrete return type on this method it works. E.g: @RequestMapping("/**")
p
crush I'm trying to create a runner in postman, but first I need to get all usernames from some JSON, but I'm having trouble getting a list of all usernames from the following JSON. var data = JSON.parse(responseBody);
$.each(data.users, function
Ahmedalipo Lodge I have web api controllers and am using this configuration method in the WebApiConfig file to camel case the results of all the controllers. var json = GlobalConfiguration.Configuration.Formatters.JsonFormatter;
json.SerializerSettings.Contrac
Ahmedalipo Lodge I have web api controllers and am using this configuration method in the WebApiConfig file to camel case the results of all the controllers. var json = GlobalConfiguration.Configuration.Formatters.JsonFormatter;
json.SerializerSettings.Contrac