|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openqa.selenium.By
org.zkoss.ztl.ClientWidget
org.zkoss.ztl.JQuery
public class JQuery
A simulator of JQuery client side object, which wraps the JQuery client side API.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.openqa.selenium.By |
---|
org.openqa.selenium.By.ByClassName, org.openqa.selenium.By.ByCssSelector, org.openqa.selenium.By.ById, org.openqa.selenium.By.ByLinkText, org.openqa.selenium.By.ByName, org.openqa.selenium.By.ByPartialLinkText, org.openqa.selenium.By.ByTagName, org.openqa.selenium.By.ByXPath |
Field Summary |
---|
Fields inherited from class org.zkoss.ztl.ClientWidget |
---|
_out |
Constructor Summary | |
---|---|
JQuery(ClientWidget el)
|
|
JQuery(java.lang.String uuid)
|
|
JQuery(java.lang.StringBuffer out)
|
|
JQuery(java.lang.StringBuffer out,
java.lang.String script)
|
Method Summary | |
---|---|
java.lang.String |
attr(java.lang.String name)
Returns the attribute value from the given name. |
JQuery |
children()
Returns the child element in JQuery object. |
JQuery |
children(java.lang.String selector)
Returns the child element in JQuery object. |
java.lang.String |
css(java.lang.String name)
Returns the CSS value from the given name. |
JQuery |
eq(int index)
proxy for jQuery eq method |
boolean |
exists()
Returns whether the widget exists or not. |
JQuery |
find(java.lang.String selector)
Finds the element from the given selector. |
JQuery |
first()
Returns the first element in JQuery object. |
Element |
get(int index)
proxy for jQuery get method |
boolean |
hasClass(java.lang.String className)
Returns whether includes the className. |
int |
height()
Returns the current computed height for the first element. |
java.lang.String |
html()
Returns the html content(innerHTML) |
int |
innerHeight()
Returns the current computed height for the first element, including padding but not border. |
int |
innerWidth()
Returns the current computed width for the first element, including padding but not border. |
boolean |
is(java.lang.String selector)
check the jquery element match the selector. |
boolean |
isVisible()
a short cut for visble |
java.util.Iterator<JQuery> |
iterator()
|
JQuery |
last()
Returns the last element in JQuery object. |
int |
length()
Returns the length of the array from the jQuery object. |
JQuery |
next()
Returns the next element in JQuery object. |
int |
offsetLeft()
Returns the current computed offsetLeft for the first element |
int |
offsetTop()
Returns the current computed offsetTop for the first element |
int |
outerHeight()
Returns the current computed height for the first element, including padding and border. |
int |
outerHeight(boolean includeMargin)
Returns the current computed height for the first element, including padding and border, it will including margin, if true |
int |
outerWidth()
Returns the current computed width for the first element, including padding and border. |
int |
outerWidth(boolean includeMargin)
Returns the current computed width for the first element, including padding and border, it will including margin, if true |
JQuery |
parent()
Returns the parent element in JQuery object. |
JQuery |
parent(java.lang.String selector)
Returns the parent element in JQuery object. |
JQuery |
parents(java.lang.String selector)
Returns the parents element in JQuery object. |
int |
positionLeft()
Returns the current computed positionLeft (the offsetLeft relative to the parent) for the first element |
int |
positionTop()
Returns the current computed positionTop (the offsetTop relative to the parent) for the first element |
JQuery |
prev()
Returns the previous element in JQuery object. |
static int |
scrollbarWidth()
Returns the scrollbar width. |
int |
scrollHeight()
Note:This not a jQuery base method. |
int |
scrollLeft()
getter for scrollLeft if multiple result , will receive first value. |
void |
scrollLeft(int value)
setter for scrollLeft |
int |
scrollTop()
getter for scrollTop if multiple result , will receive first value. |
void |
scrollTop(int value)
setter for scrollTop |
int |
scrollWidth()
Note:This not a jQuery base method. |
java.lang.String |
text()
Returns the text content |
org.openqa.selenium.By |
toBy()
Returns the element as By element, if possible. |
Element |
toElement()
Returns the element from this client widget. |
Widget |
toWidget()
translate to widget. |
java.lang.String |
val()
Returns the current value of the first element in the set of matched elements. |
int |
width()
Returns the current computed width for the first element. |
ZK |
zk()
Switches to the ZK object. |
Methods inherited from class org.zkoss.ztl.ClientWidget |
---|
eval, eval, findElements, isBlank, isEmpty, toLocator, toString, toUpperCase |
Methods inherited from class org.openqa.selenium.By |
---|
className, cssSelector, equals, findElement, hashCode, id, linkText, name, partialLinkText, tagName, xpath |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JQuery(java.lang.String uuid)
public JQuery(ClientWidget el)
public JQuery(java.lang.StringBuffer out, java.lang.String script)
public JQuery(java.lang.StringBuffer out)
Method Detail |
---|
public java.lang.String css(java.lang.String name)
name
- CSS name.public java.lang.String attr(java.lang.String name)
name
- attribute name of the element.public boolean hasClass(java.lang.String className)
className
- the CSS class name.public boolean is(java.lang.String selector)
selector
- the JQuery allowed
public boolean isVisible()
public JQuery find(java.lang.String selector)
selector
- the JQuery allowed.public JQuery first()
public JQuery last()
public JQuery prev()
public JQuery next()
public JQuery children()
public JQuery children(java.lang.String selector)
public JQuery parent()
public JQuery parent(java.lang.String selector)
public JQuery parents(java.lang.String selector)
public java.lang.String text()
public java.lang.String html()
public java.lang.String val()
public int height()
public int width()
public int innerHeight()
public int innerWidth()
public int outerWidth()
public int outerWidth(boolean includeMargin)
boolean
- includeMarginpublic int outerHeight()
public int outerHeight(boolean includeMargin)
boolean
- includeMarginpublic int length()
public ZK zk()
public org.openqa.selenium.By toBy()
ClientWidget
toBy
in class ClientWidget
public static int scrollbarWidth()
public boolean exists()
public int offsetLeft()
public int offsetTop()
public int positionLeft()
public int positionTop()
public int scrollTop()
public void scrollTop(int value)
value
- public int scrollLeft()
public void scrollLeft(int value)
value
- public int scrollHeight()
public int scrollWidth()
public Element get(int index)
index
-
public Element toElement()
ClientWidget
toElement
in class ClientWidget
public JQuery eq(int index)
index
-
public java.util.Iterator<JQuery> iterator()
iterator
in interface java.lang.Iterable<JQuery>
public Widget toWidget()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |