@SessionScoped public class ModuleGenerator extends Object implements Serializable
Constructor and Description |
---|
ModuleGenerator() |
Modifier and Type | Method and Description |
---|---|
StringBuffer |
generateBean(NGBean bean)
this method concern is the generation of the AngularJS service from the @AngularBean
CDI bean.
|
String |
getContextPath() |
void |
getScript(StringBuffer jsBuffer)
this method generate the angular-beans.js content and write it to the
jsBuffer used by BootServlet |
String |
getUID() |
void |
init()
since the NGSession scope lifecycle is the same as the current HTTP
session a unique sessionId by http session, we use the same session id
|
void |
setContextPath(String contextPath) |
@PostConstruct public void init()
public String getUID()
public void getScript(StringBuffer jsBuffer)
jsBuffer
- public StringBuffer generateBean(NGBean bean)
bean
- the bean wrapper for an @AngularBean CDI bean.public void setContextPath(String contextPath)
public String getContextPath()
Copyright © 2015. All rights reserved.