Skip to main content
View by: Most Recent | Topic | Community | Webloggers   
Monthly Archives:    

Blogs by topic: Java Enterprise

• Accessibility • Ajax • Blogging • Business • Community 
• Databases • Deployment • Distributed • Eclipse • Education 
• EJB • Extreme Programming • Games • GlassFish • Grid 
• GUI • IDE • Instant Messaging • J2EE • J2ME 
• J2SE • Jakarta • JavaFX • JavaOne • Jini 
• JSP • JSR • JXTA • LDAP • Linux 
• Mobility • NetBeans • Open Source • OpenSolaris • OSGi 
• P2P • Patterns • Performance • Porting • Programming 
• Research • RMI • RSS Feeds • Search • Security 
• Servlets • Struts • Swing • Testing • Tools 
• Virtual Machine • Web Applications • Web Design • Web Development Tools • Web Services and XML 


J2EE

How do you use the JSF NumberConverter? If you are outputting a value, how would you show a currency code along with it? <html xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core">  <h:outputText value="#{user.income}">   <f:convertNumber currencySymbol="USD" type="currency"/...
on Oct 2, 2012
See what the JSF Validator API is about! The definition of a Converter according to the Converter interface:   Object getAsObject(FacesContext context, UIComponent component, String value)  String getAsString(FacesContext context, UIComponent component, Object value) The Faces Context is passed in so the converter can introspect various aspects of the request and response. The UI...
on Sep 21, 2012
Introduction to JSF Converters During the JSF lifecycle each input value needs to be converted. As such the JSF runtime allows you to write converters that will take care of that during request processing. Several standard converters are part of the standard JSF runtime. Note that the specification has been written with extension in mind so it is also possible to write your own converter...
on Sep 21, 2012
The following blog articles are part of the JSF Validator series Introduction to JSF Validators The JSF Validator API The LengthValidator The LongRangeValidator The DoubleRangeValidator The RegexValidator The RequiredValidator Writing your own Validator Packaging your JSF Validator Multiple component validation The BeanValidator The FacesValidator annotation
on Sep 17, 2012
In the previous blog entry titled "Writing your own validator" you learned how to write a validator and hook it up for validation. At that time we made it all work using the faces-config.xml file. There is however another way, which we will describe below!   package nohelloworld;  @FacesValidator(value="NoHelloWorldValidator")  public class NoHelloWorldValidator...
on Sep 17, 2012
Since JSF 2 it is also possible to use BeanValidation as specified in JSR 303. The following blog article describes how this JSR has been integrated within JSF 2. With the following JSF managed bean. public class UserInfo {    /**     * Stores the username.     */    private String username;    /** ...
on Sep 17, 2012
Writing your own validator is a straightforward process. It involves implementing the Validator API and making sure you register it properly. Say you want to write a validator that will not allow you to use the string "Hello World" as a value.   package nohelloworld;  public class NoHelloWorldValidator implements Validator {        public void...
on Sep 9, 2012
Say you want to make sure that a value is required. <html xmlns:h="http://java.sun.com/jsf/html"  xmlns:f="http://java.sun.com/jsf/core">  <h:inputText value="#{user.firstName}">   <f:validateRequired/>  </h:inputText> </html> If you want to disable the RequiredValidator on a page you can...
on Sep 7, 2012
If you want to validate input against a regular expression then you would use the RegexValidator. Say you want to make sure only letters are used for a name. <html xmlns:h="http://java.sun.com/jsf/html"  xmlns:f="http://java.sun.com/jsf/core">  <h:inputText value="#{user.firstName}">   <f:validateRegex pattern=...
on Sep 6, 2012
Just like the LongRangeValidator before the DoubleRangeValidator validates if the given value is within the given range, but then a range of doubles. Say you want to make sure your donors can donate as little as 1.00 but at most 250.00. <html xmlns:h="http://java.sun.com/jsf/html"  xmlns:f="http://java.sun.com/jsf/core">  <h:inputText value=...
on Sep 5, 2012
The LengthValidator is one of the standard validators that is specified by the JavaServerFaces specification. It allows you to verify (validate) if the proposed input (submitted value) on a given component is valid. Say you want to make sure the minimum length of a password is 6 characters and up to 12 characters. The example below describe how you would put this into a JSF page to make that...
on Sep 4, 2012
During the JSF lifecycle each input value can be validated. As such the JSF runtime allows you to write validators that will take care of that during request processing. Several standard validators are part of the standard JSF runtime. Note that the specification has been written with extension in mind so it is also possible to write your own validator and hook it up for request processing...
on Sep 1, 2012

Community

Oracle just give free ADF Essential on Glassfish, a streamline edition of ADF. An interesting thing is there are also OEPE (Oracle Eclipse Plugins) that have ADF inside. which the Jdeveloper edition is far more complete and rich. www.oracle.com/technetwork/developer-tools/adf ADF Essential is free for glassfish deployment, and with support US$ 1250/server (/core??), and you will get the source....
on Sep 29, 2012
Creating a Reusable Service (by Jos Dirksen, Author of "SOA Governance") August 29, 2012 Manning Publications Co. Having a standard-based search engine as an access point to your service is a good way to improve the reusability of your service. In this article based on chapter 4 of SOA Governance in Action, author Jos Dirksen presents you with a couple of guidelines that can help you in...
on Sep 5, 2012

Databases

by Raymond Roestenburg and Rob Bakker, authors of Akka in Action Save 40% on Akka in Action and other selected books. ScalaTest is a xUnit style testing framework. An actor is an object that can be reached through an address, processes messages from a mailbox and sends messages to other actors using the same type of addresses. An actor encapsulates state; it does not share this state with...
on Sep 28, 2012
by Dan McCreary and Ann Kelly, Authors of Making Sense of NoSQL Bigtable systems are important NoSQL data architecture patterns because they can quickly scale to manage large data volumes. They are also known to be closely tied with many MapReduce systems. In this article from Making Sense of NoSQL, the authors discuss how Bigtable systems store data using row and column keys and how they...
on Sep 10, 2012

Testing

Acceptance Test Driven Development (ATDD) is a very effective development practice that essentially involves writing specifications in the form of documented and automated examples. These automated examples become automated acceptance tests that validate the features being delivered. The process of writing these examples encourages teams to focus on where the business value of a feature is coming...
on Sep 12, 2012

Web Applications

If you want to make sure a value is within given Long range then the LongRangeValidator is for you! Say you want to make sure your users are at least 13 but at most 18. <html xmlns:h="http://java.sun.com/jsf/html"  xmlns:f="http://java.sun.com/jsf/core">  <h:inputText value="#{user.age}">   <f:validateLongRange...
on Sep 5, 2012

Programming

JSR 359 has been accepted by Java SE/EE executive committee a month back. Please see the specification request for the content of this revision of SIP Servlet 2.0 specification. We have established a java.net project for cordinating and communicating the progress of the specification. The work is about to get started. At the moment, the expert group is being formed and some of the leading...
on Sep 3, 2012

Web Design

The definition of a Validator according to the Validator interface: void validate(FacesContext context, UIComponent component, Object value) throws ValidatorException The Faces Context is passed in so the validator can introspect various aspects of the request and response. The UI component is passed in because the actual value will be stored in that UI component after it has been...
on Sep 3, 2012