What this book covers
Chapter 1, Getting Started with PrimeFaces, provides details on the setup and configuration of PrimeFaces, along with the core concepts for every web application powered by PrimeFaces. The chapter gives a sneak preview of the basic features of PrimeFaces, such as AJAX processing and updating, component referencing by keywords and selectors, partial submitting, handling with Internationalization and Localization, along with the right-to-left language support and resource ordering.
Chapter 2, Theming Concepts, introduces PrimeFaces themes and the concept involved. Readers will learn about the theming of PrimeFaces components. The difference between structural and skinning CSS, installing and customizing PrimeFaces themes, along with creating new themes, will be detailed. Readers will also see how to adjust the font family and the font size throughout the PrimeFaces components to provide a consistent look and feel. Discussions of two variants of theme switchers and integrating additional icons finish this chapter.
Chapter 3, Enhanced Inputs and Selects, explains how to work with the input and select components available in PrimeFaces. Such components are the main parts of every web application. PrimeFaces provides nearly 25 components for data input that extend the standard JSF component suite with user-friendly interfaces, skinning capabilities, AJAX interactions, Client-side Validation, and many other useful features.
Chapter 4, Grouping Content with Panels, covers various container components, such as panel, accordion, scrollPanel, tabView, and dashboard, which allow grouping of JSF components. Various settings to configure panel components are detailed in this chapter. Furthermore, the chapter explains how to create complex layouts with the layout component and also responsive layouts for mobile devices and desktops with Grid CSS.
Chapter 5, Data Iteration Components, covers basic and advanced features to visualize data with data iteration components provided by PrimeFaces, including dataTable, dataList, pickList, orderList, tree, and treeTable. The discussed features include sorting, pagination, filtering, lazy loading, and single and multiple selections. Advanced data visualization with the schedule and dataScroller components will be demonstrated as well.
Chapter 6, Endless Menu Variations, explains several menu variations. PrimeFaces' menus fulfill all major requirements. They come with various facets—static, dynamic, tiered, hybrid, iPod-styled, and so on—and leave nothing to be desired. Readers will face a lot of recipes that discuss the menu's structure, configuration options, customizations, and integration with other components. At the end of this chapter, readers will know what kind of menu to choose and how to put it on a page for a particular use case.
Chapter 7, Working with Files, Images, and Multimedia, provides ways of managing operations on files such as uploading and downloading, image operations such as capturing, cropping, and displaying images with galleria, imageSwitch, and contentFlow. Readers will learn basic as well as advanced configuration of components and use cases.
Chapter 8, Drag Me, Drop Me, explains how the drag and drop utilities in PrimeFaces allow you to create draggable and droppable user interfaces efficiently. They abstract developers from dealing with implementation details on the browser level. In this chapter, readers will learn about PrimeFaces' drag and drop utilities—Draggable and Droppable. AJAX-enhanced drag and drop and a special integration with data iteration components will be explained as well.
Chapter 9, Creating Charts and Maps, covers the ways to create visual charts with PrimeFaces' extensive charting features and create maps based on Google Maps. PrimeFaces offers basic and advanced charting with its easy-to-use and user-friendly charting infrastructure. Throughout the chapter, mapping abilities such as drawing polylines and polygons and handling markers and events are covered as well.
Chapter 10, Client-side Validation, gives advice on how to implement Client-side Validation (CSV) with PrimeFaces. PrimeFaces' Client Side Validation Framework is the most complete and advanced CSV solution for JSF. Readers will learn all CSV tricks—configuration, standard validation, instant validation, and integration with Bean Validation. They will also meet custom client-side validators and find out how to extend CSV with JSF validators and Bean Validation.
Chapter 11, Miscellaneous Advanced Use Cases, introduces more interesting features of the PrimeFaces library. You will learn about RequestContext—a helpful utility that allows marking components as updatable targets at runtime, adding AJAX callback parameters, opening external pages in dynamically generated dialog (Dialog Framework), and more. In this chapter, a number of real-world samples will be also developed—blocking UI during AJAX calls, periodic polling, focus handling, controlling from submission, sticking components, content caching, and targetable messages, to name a few. Furthermore, after reading this chapter, readers will be aware of the pitfalls of menus within layout units and nested panels as well as possibilities for exception handling.