com.wewebu.ow.server.plug.owshortcut
Class OwShortCutItem

java.lang.Object
  extended by com.wewebu.ow.server.plug.owshortcut.OwShortCutItem
Direct Known Subclasses:
OwShortCutItemOwObject, OwShortcutItemUnresolved

public abstract class OwShortCutItem
extends Object

Abstract class that defines a short cut entry that can be displayed and executed.

Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.

For licensing information read the license.txt file or
go to: http://wiki.alfresco.com


Field Summary
protected  String persistentId
          The id used to persist this item.
protected static String TYPE_DELIMITER
          delimiter for the type in the persist string
 
Constructor Summary
OwShortCutItem()
           
 
Method Summary
abstract  String getId()
          get the ID of the shortcut
abstract  String getName()
          get the name of the shortcut
 String getPersistentId()
          Get the ID used to persist this item.
protected abstract  String getPersistString()
          get a string that persists the short cut.
abstract  int getType()
          get the type of the short cut as defined in OwClipboard.CONTENT_TYPE_...
abstract  void insertIcon(OwShortCutItemContext context_p, Writer w_p)
          render a icon link for this short cut
abstract  void insertLabel(OwShortCutItemContext context_p, Writer w_p)
          render a label link for this short cut
static OwShortCutItem loadShortCut(String persistString_p, OwShortCutItemContext context_p, int maxChildSize_p)
          factory method to create a persistent short cut from given string
abstract  void refresh(com.wewebu.ow.server.ecm.OwRepository repository_p)
          Refresh current OwShortCutItem to have the latest version of the object.
 String saveShortCut()
          save the short cut to string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_DELIMITER

protected static final String TYPE_DELIMITER
delimiter for the type in the persist string

See Also:
Constant Field Values

persistentId

protected String persistentId
The id used to persist this item.

Since:
3.1.0.3
Constructor Detail

OwShortCutItem

public OwShortCutItem()
Method Detail

insertIcon

public abstract void insertIcon(OwShortCutItemContext context_p,
                                Writer w_p)
                         throws Exception
render a icon link for this short cut

Throws:
Exception

insertLabel

public abstract void insertLabel(OwShortCutItemContext context_p,
                                 Writer w_p)
                          throws Exception
render a label link for this short cut

Throws:
Exception

getPersistString

protected abstract String getPersistString()
                                    throws Exception
get a string that persists the short cut. Used in string constructor.

Throws:
Exception

getType

public abstract int getType()
get the type of the short cut as defined in OwClipboard.CONTENT_TYPE_...


getId

public abstract String getId()
                      throws Exception
get the ID of the shortcut

Returns:
the ID Sring
Throws:
Exception

getPersistentId

public String getPersistentId()
                       throws Exception
Get the ID used to persist this item.

Throws:
Exception
Since:
3.1.0.3

getName

public abstract String getName()
get the name of the shortcut

Returns:
the name String

saveShortCut

public String saveShortCut()
                    throws OwShortCutException
save the short cut to string

Returns:
String
Throws:
OwShortCutException

loadShortCut

public static OwShortCutItem loadShortCut(String persistString_p,
                                          OwShortCutItemContext context_p,
                                          int maxChildSize_p)
                                   throws com.wewebu.ow.server.exceptions.OwException
factory method to create a persistent short cut from given string

Parameters:
persistString_p -
context_p -
maxChildSize_p - number of maximum children to be searched when retrieving the pointed object reference
Returns:
OwShortCutItem
Throws:
com.wewebu.ow.server.exceptions.OwException - mostly OwShortCutException if creation of short is failing

refresh

public abstract void refresh(com.wewebu.ow.server.ecm.OwRepository repository_p)
Refresh current OwShortCutItem to have the latest version of the object.

Parameters:
repository_p - - the repository
Since:
3.1.0.3


Copyright © 2013 Alfresco Business Solutions. All Rights Reserved.