@GlobalCommand"

From Documentation
Line 17: Line 17:
 
The optional annotation's element is a String for command's name and that name is referenced in a ZUL with global command binding. If it's not provided, method name is set as the command name by default.
 
The optional annotation's element is a String for command's name and that name is referenced in a ZUL with global command binding. If it's not provided, method name is set as the command name by default.
  
We can use parameter related annotation on command method's parameters, please refer to subsections of [[ZK Developer's Reference/MVVM/Syntax/ViewModel/Parameters]].
+
We can use parameter related annotation on command method's parameters, please refer to subsections of [[ZK Developer's Reference/MVVM/Syntax/ViewModel/Parameters | Parameters]] for more information.
  
 
= Example =
 
= Example =

Revision as of 04:41, 10 February 2012

Syntax

@GlobalCommand

@GlobalCommand("commanName") 

@GlobalCommand({"commanName1", "commandName2"})

Description

Target: method

Purpose: To identify a global command method.

The optional annotation's element is a String for command's name and that name is referenced in a ZUL with global command binding. If it's not provided, method name is set as the command name by default.

We can use parameter related annotation on command method's parameters, please refer to subsections of Parameters for more information.

Example

Method name as command name

	@GlobalCommand
	public void show(){
		//...
	}

Specify command name

	@Command("delete") @GlobalCommand("delete")
	public void deleteOrder(){
		//...
	}



Version History

Last Update : 2012/02/10


Version Date Content
6.0.0 February 2012 The MVVM was introduced.




Last Update : 2012/02/10

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.