concept OGNL expression language in category java

This is an excerpt from Manning's book Struts 2 in Action.
The following code snippet, from our Struts 2 Portfolio application’s RegistrationSuccess.jsp, shows a Struts 2 tag using the OGNL expression language:
The OGNL expression language is the bit inside the double quotes of the value attribute. This Struts 2 property tag takes a value from a property on one of our Java objects and writes it into the HTML in place of the tag. This is the point of expression languages. They allow us to use a simplified syntax to reference objects that reside in the Java environment. The OGNL expression language can be much more complex than this single element expression; it even supports such advanced features as invoking method calls on the Java objects that it can access, but the whole idea of an expression language is to simplify access to data.
Now, we’ll focus on the OGNL expression language (EL) in the context of data exiting the framework through the Struts 2 tag API. While the previous chapter showed us how to map incoming request parameters to Java properties exposed on the ValueStack, this chapter will show you how to pull data off of those properties for the rendering of result pages. We’ll explore the syntax of the OGNL EL and study the locations from which it can pull data. In particular, we’ll look closely at the ValueStack and the ActionContext. These objects hold all of the data important to processing a given request, including your action object. While it may be possible to blissfully ignore their existence during much of your development, we think the benefits are too high not to spend a few minutes getting to know them.
But that won’t take long, and we’ll make the most of the remainder of the chapter. After we demystify these two obscure repositories, we’ll provide a reference-style catalog of the general-use tags in the Struts 2 tag API. These powerful new tags allow you to wield the OGNL expression language to feed them with values. But tags are tags, and they also won’t take long to cover. So, after covering the tags, we’ll provide a concise primer to the advanced features of the OGNL expression language. In the end, you’ll wield your OGNL expressions confidently as you navigate through the densest of object graphs to pull data into the dynamic rendering of your view pages. Bon appétit.