public class OwClipboard extends Object
Clipboard object, holds a list of clipboard items for cut, copy, paste functions.
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
Modifier and Type | Class and Description |
---|---|
static interface |
OwClipboard.OwClipboardContent
Clipboard item base interface for all clipboard content items.
|
static interface |
OwClipboard.OwClipboardOperation
Interface for clipboard operation type.
|
Modifier and Type | Field and Description |
---|---|
static int |
CONTENT_TYPE_EMPTY
clipboard content type definition
|
static int |
CONTENT_TYPE_OW_FIELD
clipboard content type definition for Fields
|
static int |
CONTENT_TYPE_OW_OBJECT
clipboard content type definition
|
static int |
CONTENT_TYPE_OW_WORKITEM
clipboard content type definition
|
static OwClipboard.OwClipboardOperation |
COPY
the COPY operation.
|
static OwClipboard.OwClipboardOperation |
CUT
the CUT operation
|
protected List<OwClipboard.OwClipboardContent> |
m_contentList
list with OwClipboardContent Items
|
protected int |
m_iContentType
the current content type in the clipboard
|
Constructor and Description |
---|
OwClipboard() |
Modifier and Type | Method and Description |
---|---|
void |
addContent(OwField content_p)
Add content (field content) to the clipboard.
|
void |
addContent(OwObject content_p,
OwObject parent_p)
add an OwObject type item
|
boolean |
canAdd()
Check if the maximum object size for clipboard was reached.
|
void |
clearContent()
empty the clipboard
|
List<OwClipboard.OwClipboardContent> |
getContent()
get the contained clipboard OwClipboardContent items as an iterator
|
int |
getContentType()
get the type of the current content
|
boolean |
getCut()
get the mark the clipboard content as cut flag, i.e.
|
void |
init(OwMainAppContext owMainAppContext_p)
Initialize the clipboard
|
void |
postWarningMessage()
Post a warning message.
|
void |
setContent(List clipboarditems_p,
int iContenttype_p)
set the content of the clipboard
|
void |
setContent(OwField content_p)
Set the content of the field to clipboard.
|
void |
setContent(OwObject content_p,
OwObject parent_p)
set a single OwObject type item
|
void |
setCut()
mark the clipboard content as cut, i.e.
|
void |
setCut(boolean flag_p)
mark the clipboard content cut for flag==true, as copy for flag==false
i.e.
|
public static final int CONTENT_TYPE_EMPTY
public static final int CONTENT_TYPE_OW_OBJECT
public static final int CONTENT_TYPE_OW_WORKITEM
public static final int CONTENT_TYPE_OW_FIELD
public static final OwClipboard.OwClipboardOperation COPY
public static final OwClipboard.OwClipboardOperation CUT
protected int m_iContentType
protected List<OwClipboard.OwClipboardContent> m_contentList
public List<OwClipboard.OwClipboardContent> getContent()
public void setContent(OwObject content_p, OwObject parent_p) throws Exception
content_p
- the clipboard content objectparent_p
- the parent object used for cut operation, can be nullException
public void setCut()
public void setCut(boolean flag_p)
flag_p
- public boolean getCut()
public void setContent(List clipboarditems_p, int iContenttype_p)
clipboarditems_p
- list of OwClipboardContent itemsiContenttype_p
- int as defined with CONTENT_TYPE_...public void addContent(OwObject content_p, OwObject parent_p) throws Exception
content_p
- the clipboard content objectparent_p
- the parent object used for cut operation, can be nullException
public void clearContent()
public int getContentType()
public void addContent(OwField content_p) throws Exception
content_p
- - the fieldException
public void setContent(OwField content_p) throws Exception
content_p
- - the fieldException
public boolean canAdd()
true
if the item can be added to clipboard.public void postWarningMessage()
public void init(OwMainAppContext owMainAppContext_p)
owMainAppContext_p
- Copyright © 2014 Alfresco Business Solutions. All Rights Reserved.