Skip to end of metadata
Go to start of metadata

Introduction

One of the key strength in WebUI.NET Framework is the new Client Side Object Framework. The WebUI.NET Framework does not only contains server-side class libraries used in .NET Environment, it also invented tremendous libraries and resources in the client side for better OOP Structure and design consistency in high-end components that derive from the Framework.

The Client Side Object Framework (further called CSOF) fully takes advantage of JScript language to provide true inheritance object model to expose common properties and methods to all WebUI Studio.NET (further called WS.NET) components. The parallel consistency between client side and server side object model really introduced a new achievement and capability in increasing developer's productivity.

One of the biggest advantage that can be seen in CSOF is the engine-model libraries replacing traditional global functions which took more memory consumption and thus impacting client side performance. Although the engine classes are not intended to be used by developers directly, we have made all necessary functionalities to be accessible in the Object level and performing mapping to the engine libraries. The engine model also allow multiple version of libraries to be run simultaneously between different version of components, enabling long-term investment for mature, rock-solid high-end components.

Design Consistency

The result of the inheritance and many new features available in CSOF that we can see is the ability to access any WS.NET instances in client side with only one single function. In this purpose, Intersoft has taken the giant steps to really focusing on developer's productivity. For example, in common ASP.NET components, one has to remember the function name to access the object for each component. Imagine if you have about 10 components in a page where you need to access them in scripting, then you would have to remember 10 function names. This is no longer required by the introduction of CSOF. See following sample codes for better pictures:

Traditional Object Access:

var compA = xx_GetCompAById("compAID");

var compB = xx_GetCompBById("compBID");

CSOF Object Access:

var compA = ISGetObject("compAID");

var compB = ISGetObject("compBID");

You can access any WS.NET instances easily by using one single function ISGetObject. This will certainly result in greater productivity where developers can concentrate on their business logic, instead of spending time in inconsistency of each components they used.

Object Structure

Any WS.NET members should be automatically derive from the CSOF and therefore should meet the requirements and new standard in client object's structure. The CSOF requires the object's structure to be as similar as possible against the server side object model including the name of the properties and the hierarchy of public objects. This will in return producing self-understandable syntax and properties. You can consider the client side object structure as a mini-version of server side object.

See following example for details:

Server Side Object Model:

WebInput1.EditFormat.MaskInfo.MaskExpression

Client Side Object Model:

var input1 = ISGetObject("WebInput1");

alert(input1.EditFormat.MaskInfo.MaskExpression);

Notice that you can get the same property's value in client side by following the same object hierarchy and property name.

Events

Any WS.NET members are automatically taking advantage of the common client side events available in a W3C browser context. Following is the list of common client side events available in control-level implemented by any WS.NET members as a standard:

  • OnBlur
  • OnChange
  • OnClick
  • OnDblClick
  • OnFocus
  • OnKeyDown
  • OnKeyPress
  • OnKeyUp
  • OnMouseDown
  • OnMouseMove
  • OnMouseOut
  • OnMouseUp
  • OnSelect

Each client side event now expose at least 1 parameter, that is the controlId. The controlId is actually the ClientID of the server control, enabling the script to run properly when running in complex user control or portal-based environment.

 

In addition to the common client side events above, there are more client side events that are specifically exposed for each component's functionalities. For instance, WebInput.NET exposes OnAfterValidate for masking validation purpose.
 

 
The common client side events above are available at control level, the CSOF also introduces client side events specifically for element level such as following:
  • OnClick
  • OnDblClick
  • OnMouseDown
  • OnMouseMove
  • OnMouseOut
  • OnMouseOver
  • OnMouseUp

These client side events are specifically designed for element such as DropdownButton, CalculatorOperandEvents etc. These events also expose at least 1 parameter, the controlId as the standard.

 

WebUI.NET Framework also includes Client Event Designer to accompany the CSOF architecture in visual design time environment. To learn more about Client Event Designer, please click the link in the See Also section below.
 

Rich Libraries

 In addition to the inheritance, integration, engine classes and events architecture introduced in CSOF, it also provides a rich client side libraries to be used by WS.NET members. There are several public objects that are implemented at CSOF and available to use by WS.NET members for both UI and scripting purpose such as following:

  • Dimension
  • Listener
  • WindowInfo
  • OffsetLocation
  • ClientEditor
  • Settings
  • CommonElementClientSideEvents
  • DynamicStyle
  • CultureInfo
  • CoreValidator