|
LEONARDI Application Composer - 8.9.0.40 by W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectleon.view.LyViewManager
leon.view.web.LyWebViewManager
leon.view.web.jquery.LyJQViewManager
public class LyJQViewManager
Communication control layer --> View Will implement remote update notifications.
Field Summary | |
---|---|
static boolean |
USE_ABSOLUTE_ROOT_URL
Indicates whether an absolute URL must be used as a root url. |
Constructor Summary | |
---|---|
LyJQViewManager(LyEnvironment environment)
Constructor. |
Method Summary | |
---|---|
void |
addSharingManager(javax.servlet.http.HttpSession sharingHttpSession,
LyJQSession sharingSession)
Register a view manager sharing current view manager session. |
void |
addToReloadComponents(LyComponent object)
|
void |
addToUpdateScript(java.lang.String updateScript)
|
LyAnswerInterface |
answerMessage(java.lang.String infoId,
boolean result)
Answer the interface by calling the answer associated to message associated to the given ID. |
LyAnswerInterface |
answerMessage(java.lang.String infoId,
short result)
Answer the interface by calling the answer associated to message associated to the given ID. |
boolean |
areViewManagerCompatible(LyViewManager otherViewManager)
Check if this view manager is compatible with the given view manager |
LyViewComponent |
buildInternalView(LyComponent component)
(non-Javadoc). |
void |
copyToClipboard(java.lang.String text)
Copy a given text to the system clipboard. |
void |
emptyRefreshScripts()
|
void |
exit(int code)
(non-Javadoc). |
void |
free()
Free the view manager. |
void |
freeImage(java.lang.Object image)
Free the resources of the image if not in the cache. |
java.lang.Object |
getColor(LyColor color)
(non-Javadoc). |
java.lang.String |
getCookieTheme(javax.servlet.http.HttpServletRequest request)
Return the JQuery theme registered in the cookies. |
LyView |
getCurrentPrintView()
|
LyComponent |
getCurrentTreeMapView()
|
java.lang.String |
getCustomThemes()
Returns the list of available custom themes. |
java.lang.Object |
getDefaultImage()
Construct a default image. |
java.lang.String |
getDefaultPageResource()
Returns the name of the resource to be used for default page. |
java.lang.String |
getDownloadAction()
Return the action that allow to download temporary resources but dependant from the viewer type (for ex: url / partial url for web). |
java.lang.Object |
getFont(LyFont font)
(non-Javadoc). |
boolean |
getIsPortlet()
|
java.lang.String |
getNewWindowScriptsString()
|
java.lang.StringBuffer |
getReloadDivScripts(java.util.Map<java.lang.String,LyComponent> components)
get reload components scripts |
java.lang.Object |
getScaledInstance(java.lang.Object image,
int width,
int height)
Creates a scaled version of the given image. |
java.lang.String |
getScriptsDir()
Returns the url of the directory that contains the Javascript files. |
java.lang.String |
getScriptsDocDir()
Returns the path of the directory that contains the Javascript files. |
javax.servlet.ServletContext |
getServletContext()
|
java.lang.String |
getSharedSessionMessage()
Returns the message that must be displayed in the sharing box. |
LyJQViewManager |
getSharingManager(javax.servlet.http.HttpSession sharingHttpSession)
Return the view manager sharing current view manager session from a given http session. |
int[] |
getSizes(java.lang.Object image)
Gets images sizes. |
java.lang.String |
getSlaveSessionClassName()
Returns the name of the Java class that must be used to instanciate a new slave session. |
long |
getStopPushTime()
|
int |
getStringWidth(LyFont font,
java.lang.String text)
(non-Javadoc). |
java.lang.String |
getThemes()
Returns the list of available themes. |
java.lang.String |
getUpdateScripts(boolean emptyScripts)
|
LyTemplatesUtilsBean |
getVeloTemplatesBean()
|
java.util.Vector<LyView> |
getViewList()
|
LyJQPage |
instanciatePageWriter(LyComponent component,
boolean writeDivOnly)
|
boolean |
isAutoCompleteEvent()
|
boolean |
isComponentToRefresh(java.lang.String compId)
|
boolean |
isPortletMode()
Indicates whether this view manager is in portlet mode. |
boolean |
isPrintMode()
|
boolean |
isRequestInProgress()
|
boolean |
isRtlMode()
Indicates whether RTL (right to left) mode is activated |
boolean |
isSameImage(java.lang.Object image1,
java.lang.Object image2)
Compare two images pixel by pixel. |
boolean |
isSelectedTab(LyTabs tabs,
java.lang.String tabId)
|
boolean |
isSessionClosing()
|
boolean |
isShared()
Indicates whether current view manager is being shared. |
boolean |
isSharing()
Indicates whether current view manager is sharing another view manager. |
java.lang.Object |
loadImageFromStream(java.lang.Object component,
java.io.InputStream resource)
Retrieves an image from a Stream. |
void |
redirectToHomePage()
|
void |
redirectToHomePage(LyView closedView)
Sends a Javascript script to redirect to home page. |
void |
setAutoCompleteEvent(boolean _isAutoCompleteEvent)
|
void |
setCurrentPrintView(LyView currentView)
|
void |
setCurrentTreeMapView(LyComponent view)
|
void |
setIsPortlet(boolean isportlet)
|
void |
setPopupMenu(LyPopupMenu popup)
Sets the popup menu with the given value. |
void |
setPrintMode(boolean isPrintMode)
set request print mode |
void |
setRequestInProgress(boolean inProgress)
|
void |
setServletContext(javax.servlet.ServletContext _context)
|
void |
setServletRequest(javax.servlet.http.HttpServletRequest request)
|
void |
setSessionClosing()
|
void |
setStopPush()
|
void |
shareSession(java.lang.Object sharedSession,
java.util.Vector<java.lang.Object> sharingSessions,
java.lang.String applicationId)
Share a session with other sessions. |
void |
showLocation(LyComponent source,
java.lang.String location,
boolean newWindow,
java.util.Hashtable<java.lang.Short,java.lang.String> parameters)
Shows a location to the user. |
void |
stopSharingSession()
Stop the sharing process of current session. |
void |
swapSession(java.lang.Object newSession,
java.lang.Object oldSession,
java.lang.String applicationId)
Swap two sessions. |
boolean |
useCustomizedFilecomponent()
Indicates whether file components must be customized in web browser. |
void |
waitForLoading(java.lang.Object component,
java.lang.Object image)
Waits for the image loading if the headless mode is null or set to true. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static boolean USE_ABSOLUTE_ROOT_URL
Constructor Detail |
---|
public LyJQViewManager(LyEnvironment environment)
environment
- the application environmentMethod Detail |
---|
public void free()
LyViewManager
free
in interface LyViewManagerInterface
free
in class LyWebViewManager
LyViewManagerInterface.free()
public java.lang.String getDefaultPageResource()
getDefaultPageResource
in class LyWebViewManager
public java.lang.String getScriptsDir()
getScriptsDir
in class LyWebViewManager
public java.lang.String getScriptsDocDir()
getScriptsDocDir
in class LyWebViewManager
public void swapSession(java.lang.Object newSession, java.lang.Object oldSession, java.lang.String applicationId)
swapSession
in class LyViewManager
newSession
- the new sessionoldSession
- the old sessionapplicationId
- the application idpublic void shareSession(java.lang.Object sharedSession, java.util.Vector<java.lang.Object> sharingSessions, java.lang.String applicationId)
shareSession
in class LyViewManager
sharedSession
- the shared sessionsharingSessions
- the list of sessions sharing the shared sessionapplicationId
- the application idpublic void stopSharingSession()
public void addSharingManager(javax.servlet.http.HttpSession sharingHttpSession, LyJQSession sharingSession)
sharingHttpSession
- http session of the sharing view managersharingManager
- view manager sharing current view manager sessionpublic LyJQViewManager getSharingManager(javax.servlet.http.HttpSession sharingHttpSession)
sharingHttpSession
- http session corresponding to the sharing view manager
public boolean isShared()
isShared
in class LyViewManager
public boolean isSharing()
public java.lang.String getSharedSessionMessage()
public void redirectToHomePage()
public void redirectToHomePage(LyView closedView)
public LyViewComponent buildInternalView(LyComponent component)
buildInternalView
in class LyWebViewManager
LyViewManager.buildInternalView(leon.view.LyComponent)
public java.lang.Object getColor(LyColor color)
getColor
in interface LyViewManagerInterface
getColor
in class LyViewManager
color
- The leonardi color.
LyViewManagerInterface.getColor(leon.misc.LyColor)
public java.lang.Object getFont(LyFont font)
getFont
in interface LyViewManagerInterface
getFont
in class LyViewManager
font
- The leonardi font.
LyViewManagerInterface.getFont(leon.misc.LyFont)
public int getStringWidth(LyFont font, java.lang.String text)
getStringWidth
in interface LyViewManagerInterface
getStringWidth
in class LyViewManager
font
- The leonardi font.text
- The string value.
LyViewManagerInterface.getStringWidth(leon.misc.LyFont, java.lang.String)
public java.lang.Object getDefaultImage()
getDefaultImage
in interface LyViewManagerInterface
getDefaultImage
in class LyViewManager
LyImageUtils.getDefaultImage()
,
LyViewManagerInterface.getDefaultImage()
public java.lang.Object getScaledInstance(java.lang.Object image, int width, int height)
getScaledInstance
in interface LyViewManagerInterface
getScaledInstance
in class LyViewManager
image
- The image to scale.width
- The width to which to scale the image.height
- The height to which to scale the image.
LyImageUtils.getScaledInstance(Image, int, int)
,
LyViewManagerInterface.getScaledInstance(Object, int, int)
public void waitForLoading(java.lang.Object component, java.lang.Object image) throws java.lang.InterruptedException
waitForLoading
in interface LyViewManagerInterface
waitForLoading
in class LyViewManager
component
- The image loading clientimage
- Image to load.
java.lang.InterruptedException
- if the wait is interruptuedLyImageUtils.waitForLoading(Component, Image)
,
LyViewManagerInterface.waitForLoading(Object, Object)
public boolean isSameImage(java.lang.Object image1, java.lang.Object image2) throws java.lang.InterruptedException
isSameImage
in class LyViewManager
image1
- first image to compareimage2
- second image to compare
java.lang.InterruptedException
- exception if problems on grabber or loading.LyImageUtils.isSameImage(Image, Image)
,
LyViewManager.isSameImage(java.lang.Object, java.lang.Object)
public void freeImage(java.lang.Object image)
freeImage
in interface LyViewManagerInterface
freeImage
in class LyViewManager
image
- The image that must be freed.LyImageUtils.freeImage(Image)
,
LyViewManagerInterface.freeImage(java.lang.Object)
public void exit(int code)
exit
in interface LyViewManagerInterface
exit
in class LyWebViewManager
code
- exit code of the application.LyViewManagerInterface.exit(int)
public void copyToClipboard(java.lang.String text)
copyToClipboard
in class LyViewManager
text
- the text to be copied to the clipboard.public boolean areViewManagerCompatible(LyViewManager otherViewManager)
areViewManagerCompatible
in class LyViewManager
otherViewManager
- the other view manager
public java.lang.String getDownloadAction()
LyViewManager
getDownloadAction
in class LyViewManager
public javax.servlet.ServletContext getServletContext()
public void setServletContext(javax.servlet.ServletContext _context)
_context
- the _context to setpublic void setPopupMenu(LyPopupMenu popup)
popup
- the new popup menupublic void setServletRequest(javax.servlet.http.HttpServletRequest request)
public boolean isSelectedTab(LyTabs tabs, java.lang.String tabId)
public java.lang.StringBuffer getReloadDivScripts(java.util.Map<java.lang.String,LyComponent> components)
public LyTemplatesUtilsBean getVeloTemplatesBean()
public void emptyRefreshScripts()
public int[] getSizes(java.lang.Object image)
LyViewManager
getSizes
in interface LyViewManagerInterface
getSizes
in class LyViewManager
image
- the image
public void addToUpdateScript(java.lang.String updateScript)
public void addToReloadComponents(LyComponent object)
public java.lang.String getUpdateScripts(boolean emptyScripts)
public void setRequestInProgress(boolean inProgress)
public boolean isRequestInProgress()
public void setStopPush()
public void setSessionClosing()
public boolean isSessionClosing()
public long getStopPushTime()
public java.util.Vector<LyView> getViewList()
public java.lang.String getCookieTheme(javax.servlet.http.HttpServletRequest request)
public java.lang.String getThemes()
public java.lang.String getCustomThemes()
public java.lang.Object loadImageFromStream(java.lang.Object component, java.io.InputStream resource) throws java.io.IOException
LyViewManager
loadImageFromStream
in interface LyViewManagerInterface
loadImageFromStream
in class LyViewManager
component
- The client of the image creation.resource
- stream inputStream to the image data
java.io.IOException
- if something is wrong during the processpublic LyAnswerInterface answerMessage(java.lang.String infoId, boolean result)
answerMessage
in class LyWebViewManager
infoId
- the id of the answer messageresult
- true if the user chose "yes" or "ok", false otherwise
public LyAnswerInterface answerMessage(java.lang.String infoId, short result)
answerMessage
in class LyWebViewManager
infoId
- the id of the answer messageresult
- true if the user chossed "yes" or "ok", false otherwise
public void showLocation(LyComponent source, java.lang.String location, boolean newWindow, java.util.Hashtable<java.lang.Short,java.lang.String> parameters)
LyViewManager
showLocation
in class LyWebViewManager
source
- view element which raises the locationlocation
- locationnewWindow
- indicates whether a new window must be openedparameters
- list of parameterspublic java.lang.String getNewWindowScriptsString()
public java.lang.String getSlaveSessionClassName()
getSlaveSessionClassName
in class LyViewManager
public void setPrintMode(boolean isPrintMode)
isPrintMode
- public boolean isPrintMode()
public LyComponent getCurrentTreeMapView()
public void setCurrentTreeMapView(LyComponent view)
public void setCurrentPrintView(LyView currentView)
public LyView getCurrentPrintView()
public boolean isComponentToRefresh(java.lang.String compId)
public LyJQPage instanciatePageWriter(LyComponent component, boolean writeDivOnly)
public boolean isAutoCompleteEvent()
public void setAutoCompleteEvent(boolean _isAutoCompleteEvent)
_isAutoCompleteEvent
- the _isAutoCompleteEvent to setpublic boolean useCustomizedFilecomponent()
public boolean isRtlMode()
isRtlMode
in interface LyViewManagerInterface
isRtlMode
in class LyViewManager
public boolean isPortletMode()
LyViewManager
isPortletMode
in class LyViewManager
public boolean getIsPortlet()
public void setIsPortlet(boolean isportlet)
|
(c) January 2013 - W4 S.A. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |