script.html

来自「维信SDK文档。源码要求为至少5个C或Java源码」· HTML 代码 · 共 712 行 · 第 1/3 页

HTML
712
字号
<PRE>void <B>updateReceived</B>(<A HREF="../../widsets/api/String.html" title="class in ">String</A>&nbsp;service,                    <A HREF="../../widsets/api/Value.html" title="class in ">Value</A>&nbsp;argument)</PRE><DL><DD><p>Called when asynchronous notification has been received from  server indicating that something has changed on the service associated with this widget. </p> <p>If this function is not implemented, the <A HREF="../../widsets/api/Script.html#updateWidget()"><CODE>updateWidget()</CODE></A>  will be called instead.</p><P><DD><DL><DT><B>Parameters:</B><DD><CODE>service</CODE> - Name of service<DD><CODE>argument</CODE> - Notification argument</DL></DD></DL><HR><A NAME="openWidget()"><!-- --></A><H3>openWidget</H3><PRE><A HREF="../../widsets/api/Shell.html" title="class in ">Shell</A> <B>openWidget</B>()</PRE><DL><DD>Called when the user opens the widget from the dashboard.<P><DD><DL></DL></DD></DL><HR><A NAME="closeWidget()"><!-- --></A><H3>closeWidget</H3><PRE>void <B>closeWidget</B>()</PRE><DL><DD>Called when last script-created maximized shell is popped.  This is where script should do cleaning up, like stop timers or make them occur not so often anymore, set large pictures/binaries/arrays to null, or save modified user data to store.<P><DD><DL></DL></DD></DL><HR><A NAME="timerEvent(Timer)"><!-- --></A><H3>timerEvent</H3><PRE>void <B>timerEvent</B>(<A HREF="../../widsets/api/Timer.html" title="class in ">Timer</A>&nbsp;timer)</PRE><DL><DD>Called then scheduled timer is executed.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>timer</CODE> - Scheduled timer object<DT><B>See Also:</B><DD><A HREF="../../widsets/api/API.html#schedule(long)"><CODE>schedule(long)</CODE></A>, <A HREF="../../widsets/api/API.html#schedule(long, long)"><CODE>schedule(long,long)</CODE></A>, <A HREF="../../widsets/api/Timer.html" title="class in "><CODE>Timer</CODE></A>, <A HREF="../../widsets/api/Timer.html#cancel()"><CODE>Timer.cancel()</CODE></A>, <A HREF="../../widsets/api/TimerCallback.html" title="interface in "><CODE>TimerCallback</CODE></A></DL></DD></DL><HR><A NAME="paint(Component, Graphics, Style, int, int)"><!-- --></A><H3>paint</H3><PRE>void <B>paint</B>(<A HREF="../../widsets/api/Component.html" title="class in ">Component</A>&nbsp;c,           <A HREF="../../widsets/api/Graphics.html" title="class in ">Graphics</A>&nbsp;g,           <A HREF="../../widsets/api/Style.html" title="class in ">Style</A>&nbsp;style,           int&nbsp;width,           int&nbsp;height)</PRE><DL><DD>Called when custom component should be painted. Coordinate (0,0) points to top left corner of component's rectangle. Clipping is in effect so that drawing actions are contained into area reserved for this component.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>c</CODE> - Instance of custom component<DD><CODE>g</CODE> - Graphics context<DD><CODE>style</CODE> - Style to use<DD><CODE>width</CODE> - Width of the available area<DD><CODE>height</CODE> - Height of the available area<DT><B>See Also:</B><DD><A HREF="../../widsets/api/PaintCallback.html" title="interface in "><CODE>PaintCallback</CODE></A>, <a href="package-summary.html#callback">Callbacks</a></DL></DD></DL><HR><A NAME="onSuccess(Object, Value)"><!-- --></A><H3>onSuccess</H3><PRE>void <B>onSuccess</B>(<A HREF="../../widsets/api/Object.html" title="class in ">Object</A>&nbsp;state,               <A HREF="../../widsets/api/Value.html" title="class in ">Value</A>&nbsp;returnValue)</PRE><DL><DD><p> Called when server call has finished successfully. Server calls are  made with <A HREF="../../widsets/api/API.html#call(Object, String, String, Value)"><CODE>call(Object, String, String, Value)</CODE></A> or <A HREF="../../widsets/api/API.html#call(Object, String, String, Value, SuccessCallback, FailureCallback)"><CODE>call(Object, String, String, Value, SuccessCallback, FailureCallback)</CODE></A> </p><P><DD><DL><DT><B>Parameters:</B><DD><CODE>state</CODE> - State object given with <A HREF="../../widsets/api/API.html#call(Object, String, String, Value)"><CODE>call(Object, String, String, Value)</CODE></A><DD><CODE>returnValue</CODE> - the return value from server<DT><B>See Also:</B><DD><A HREF="../../widsets/api/SuccessCallback.html" title="interface in "><CODE>SuccessCallback</CODE></A>, <a href="package-summary.html#callback">Callbacks</a></DL></DD></DL><HR><A NAME="onFailure(Object, String)"><!-- --></A><H3>onFailure</H3><PRE>void <B>onFailure</B>(<A HREF="../../widsets/api/Object.html" title="class in ">Object</A>&nbsp;state,               <A HREF="../../widsets/api/String.html" title="class in ">String</A>&nbsp;errorMessage)</PRE><DL><DD><p> Called when server call has failed. Server calls are  made with <A HREF="../../widsets/api/API.html#call(Object, String, String, Value)"><CODE>call(Object, String, String, Value)</CODE></A> or <A HREF="../../widsets/api/API.html#call(Object, String, String, Value, SuccessCallback, FailureCallback)"><CODE>call(Object, String, String, Value, SuccessCallback, FailureCallback)</CODE></A> </p><P><DD><DL><DT><B>Parameters:</B><DD><CODE>state</CODE> - State object given with <A HREF="../../widsets/api/API.html#call(Object, String, String, Value)"><CODE>call(Object, String, String, Value)</CODE></A><DD><CODE>errorMessage</CODE> - error message of exception<DT><B>See Also:</B><DD><A HREF="../../widsets/api/FailureCallback.html" title="interface in "><CODE>FailureCallback</CODE></A>, <a href="package-summary.html#callback">Callbacks</a></DL></DD></DL><HR><A NAME="messageReceived(String, Object, ResponseCallback)"><!-- --></A><H3>messageReceived</H3><PRE>void <B>messageReceived</B>(<A HREF="../../widsets/api/String.html" title="class in ">String</A>&nbsp;service,                     <A HREF="../../widsets/api/Object.html" title="class in ">Object</A>&nbsp;argument,                     ResponseCallback&nbsp;callback)</PRE><DL><DD>Called when inter widget communication request has been received.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>service</CODE> - Name of service being called<DD><CODE>argument</CODE> - Argument for service<DD><CODE>callback</CODE> - Optional callback for sending response back,                 <code>null</code> callback indicates that                  caller do not wish to receive response.</DL></DD></DL><HR><A NAME="handleMessage(String, Object)"><!-- --></A><H3>handleMessage</H3><PRE><A HREF="../../widsets/api/Object.html" title="class in ">Object</A> <B>handleMessage</B>(<A HREF="../../widsets/api/String.html" title="class in ">String</A>&nbsp;service,                     <A HREF="../../widsets/api/Object.html" title="class in ">Object</A>&nbsp;argument)</PRE><DL><DD>This privileged operation is used when java code wishes to interact  with integrated "core" widget. Not applicable to user defined widgets.<P><DD><DL></DL></DD></DL><HR><A NAME="parametersChanged()"><!-- --></A><H3>parametersChanged</H3><PRE>void <B>parametersChanged</B>()</PRE><DL><DD>Called when widget parameters are changed either from server side or client side.  Note. If this function is not declared, parameter change will close maximized mode (if widget was maximized), sync dashboard -> restart widget.<P><DD><DL></DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../widsets/api/package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../widsets/api/Prompt.html" title="class in "><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../widsets/api/Scrollable.html" title="class in "><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../index.html?widsets/api/Script.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="Script.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR></BODY></HTML>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?