JavaServer Faces

Javaserver Faces-Free PDF

  • Date:13 Jan 2021
  • Views:2
  • Downloads:0
  • Pages:25
  • Size:210.71 KB

Share Pdf : Javaserver Faces

Download and Preview : Javaserver Faces


Report CopyRight/DMCA Form For : Javaserver Faces


Transcription:

JSF aplikace,web xml taglib prefix f uri,taglib prefix h uri. faces config xml html,Faces servlet,JSF jsp body,Backing Beans java Hi. h outputText,model java value user name,expression language. 27 5 2009 CZJUG JavaServer Faces 2,taglib prefix f uri. initial request,taglib prefix h uri,h inputText,value user name.
postback request h commandButton,value send,action user store. 27 5 2009 CZJUG JavaServer Faces 3,Backing Bean,public class UserBean. private String name,private int age h outputText,public UserBean value user name. public String getName,return user initial response getter. postback response getter,public void setName String name.
this name name,h inputText,public int getAge,value user age. return age,initial response getter, public void setAge int age postback request setter. this age age postback response getter,27 5 2009 CZJUG JavaServer Faces 4. taglib prefix f Initial,uri http java sun com jsf core 1 UserBean getName. taglib prefix h,uri http java sun com jsf html Postback.
html 2 UserBean setName,head head 3 UserBean store. body 4 UserBean getName,h inputText value user name. h commandButton value send,action user store,27 5 2009 CZJUG JavaServer Faces 5. Managed Bean faces config xml,faces config,managed bean. managed bean name user managed bean name,managed bean class.
x36tjv UserBean,managed bean class,managed bean scope request managed bean scope. managed bean,faces config,request application,session none. 27 5 2009 CZJUG JavaServer Faces 6,Navigace faces config xml. faces config,navigation rule first jsp,from view id first jsp from view id. navigation case,from outcome next from outcome next.
to view id second jsp to view id,navigation case,navigation rule second jsp. faces config,statick navigace,h commandButton value send action next. 27 5 2009 CZJUG JavaServer Faces 7,Dynamick navigace. h commandButton value send action user store,public class UserBean. public String store,return home next home,return next.
second jsp home jsp,27 5 2009 CZJUG JavaServer Faces 8. h inputText value dvd year,required true,f convertDateTime pattern yyyy. h inputText,javovsk objekt, BigDecimalConverter DateTimeConverter LongConverter. BigIntegerConverter DoubleConverter NumberConverter. BooleanConverter EnumConverter ShortConverter,ByteConverter FloatConverter. CharacterConverter IntegerConverter,27 5 2009 CZJUG JavaServer Faces 9.
class PhoneConverter implements Converter,public Object getAsObject FacesContext fc. UIComponent comp String value,String Object ConverterException. public String getAsString FacesContext fc,UIComponent comp Object value. Object String ConverterException,faces config xml, converter for class x36tjv Phone converter for class. converter class x36tjv PhoneConverter converter class. 27 5 2009 CZJUG JavaServer Faces 10,form data validation.
business logic validation,h inputText value app length. f validateDoubleRange minimum 0,maximum 100,h inputText. DoubleRangeValidator,LongRangeValidator,LengthValidator d lka et zce. 27 5 2009 CZJUG JavaServer Faces 11,class PhoneValidator implements Validator. public void validate FacesContext fc,UIComponent comp Object value.
throws ValidatorException,faces config xml,validator id phoneValidator validator id. validator class x36tjv PhoneValidator validator class. h inputText value user phone,f validator validatorId phoneValidator. h inputText,27 5 2009 CZJUG JavaServer Faces 12,Lokalizace. messages en properties, f loadBundle basename messages appName DVD Library. h outputText messages cs properties,value msg appName.
appName Knihovna DVD,faces config xml,application,locale config. default locale en default locale,supported locale cs supported locale. locale config,message bundle messages message bundle. application,27 5 2009 CZJUG JavaServer Faces 13,Component Tree. Client side Server side,UIViewRoot,Welcome to JSF HtmlOutputText.
h outputText,HtmlInputText,h inputText,find HtmlCommandButton. h commandButton,27 5 2009 CZJUG JavaServer Faces 14. Request Life Cycle,postaven vy ten konverze,stromu parametr a validace. Restore Process,View Validations,Render Invoke,Response Application. vytvo en akce a ulo en,odpov di navigace hodnot,27 5 2009 CZJUG JavaServer Faces 15.
27 5 2009 CZJUG JavaServer Faces 4 Backing Bean public classUserBean privateStringname private intage public UserBean public StringgetName

Related Books