org.viewaframework.annotation
Annotation Type View


@Retention(value=RUNTIME)
@Target(value=TYPE)
public @interface View

This annotation represents a ViewContainer object and its position in the active perspective

Since:
1.0.2
Author:
Mario Garcia

Required Element Summary
 Class<? extends ViewContainer> type
          This type will be used to create or retrieve the right ViewContainer object Mandatory
 
Optional Element Summary
 String id
          This id can be used when the application has an IOC container available at its application context.
 boolean isRoot
          Whether this view is going to be the root view
 boolean isTray
          Whether this view is going to be the application's tray icon view
 PerspectiveConstraint position
          The position must match the valid constraints available for each Perspective.
 String viewId
          This is the view's id.
 

Element Detail

type

public abstract Class<? extends ViewContainer> type
This type will be used to create or retrieve the right ViewContainer object Mandatory

Returns:
The type of the ViewContainer

id

public abstract String id
This id can be used when the application has an IOC container available at its application context. The instance of the view can be retrieved from there with this id. Don't get wrong with the viewId. Optional

Returns:
Default:
""

viewId

public abstract String viewId
This is the view's id. If empty will be used the one declared in within the class. Remember that a view must always have an id in order to be added to the current perspective. Optional

Returns:
The view's id
Default:
""

position

public abstract PerspectiveConstraint position
The position must match the valid constraints available for each Perspective. By default it uses the value PerspectiveConstraint.RIGHT Optional

Returns:
The position it has within the current perspective
Default:
org.viewaframework.view.perspective.PerspectiveConstraint.RIGHT

isRoot

public abstract boolean isRoot
Whether this view is going to be the root view

Returns:
If true this view is the root view
Default:
false

isTray

public abstract boolean isTray
Whether this view is going to be the application's tray icon view

Returns:
If true this view is the tray view
Default:
false


Copyright © 2010. All Rights Reserved.