⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 condition.java

📁 一个工作流的原型
💻 JAVA
字号:
/*
 * This class was automatically generated with 
 * <a href="http://www.castor.org">Castor cvs.0.9.6</a>, using an
 * XML Schema.
 * $Id$
 */

package workflow.xwfbox.process;

  //---------------------------------/
 //- Imported classes and packages -/
//---------------------------------/

import java.io.Reader;
import java.io.Serializable;
import java.io.Writer;
import java.util.Enumeration;
import java.util.Vector;
import workflow.xwfbox.process.types.ConditionItemTypeType;

/**
 * Class Condition.
 * 
 * @version $Revision$ $Date$
 */
public class Condition implements java.io.Serializable {


      //--------------------------/
     //- Class/Member Variables -/
    //--------------------------/

    /**
     * Field _type
     */
    private workflow.xwfbox.process.types.ConditionItemTypeType _type;

    /**
     * internal content storage
     */
    private java.lang.String _content = "";

    /**
     * Field _items
     */
    private java.util.Vector _items;


      //----------------/
     //- Constructors -/
    //----------------/

    public Condition() {
        super();
        setContent("");
        _items = new Vector();
    } //-- workflow.xwfbox.process.Condition()


      //-----------/
     //- Methods -/
    //-----------/

    /**
     * Method addConditionItem
     * 
     * 
     * 
     * @param vConditionItem
     */
    public void addConditionItem(workflow.xwfbox.process.ConditionItem vConditionItem)
        throws java.lang.IndexOutOfBoundsException
    {
        _items.addElement(vConditionItem);
    } //-- void addConditionItem(workflow.xwfbox.process.ConditionItem) 

    /**
     * Method addConditionItem
     * 
     * 
     * 
     * @param index
     * @param vConditionItem
     */
    public void addConditionItem(int index, workflow.xwfbox.process.ConditionItem vConditionItem)
        throws java.lang.IndexOutOfBoundsException
    {
        _items.insertElementAt(vConditionItem, index);
    } //-- void addConditionItem(int, workflow.xwfbox.process.ConditionItem) 

    /**
     * Method enumerateConditionItem
     * 
     * 
     * 
     * @return Enumeration
     */
    public java.util.Enumeration enumerateConditionItem()
    {
        return _items.elements();
    } //-- java.util.Enumeration enumerateConditionItem() 

    /**
     * Method getConditionItem
     * 
     * 
     * 
     * @param index
     * @return ConditionItem
     */
    public workflow.xwfbox.process.ConditionItem getConditionItem(int index)
        throws java.lang.IndexOutOfBoundsException
    {
        //-- check bounds for index
        if ((index < 0) || (index > _items.size())) {
            throw new IndexOutOfBoundsException();
        }
        
        return (workflow.xwfbox.process.ConditionItem) _items.elementAt(index);
    } //-- workflow.xwfbox.process.ConditionItem getConditionItem(int) 

    /**
     * Method getConditionItem
     * 
     * 
     * 
     * @return ConditionItem
     */
    public workflow.xwfbox.process.ConditionItem[] getConditionItem()
    {
        int size = _items.size();
        workflow.xwfbox.process.ConditionItem[] mArray = new workflow.xwfbox.process.ConditionItem[size];
        for (int index = 0; index < size; index++) {
            mArray[index] = (workflow.xwfbox.process.ConditionItem) _items.elementAt(index);
        }
        return mArray;
    } //-- workflow.xwfbox.process.ConditionItem[] getConditionItem() 

    /**
     * Method getConditionItemCount
     * 
     * 
     * 
     * @return int
     */
    public int getConditionItemCount()
    {
        return _items.size();
    } //-- int getConditionItemCount() 

    /**
     * Returns the value of field 'content'. The field 'content'
     * has the following description: internal content storage
     * 
     * @return String
     * @return the value of field 'content'.
     */
    public java.lang.String getContent()
    {
        return this._content;
    } //-- java.lang.String getContent() 

    /**
     * Returns the value of field 'type'.
     * 
     * @return ConditionItemTypeType
     * @return the value of field 'type'.
     */
    public workflow.xwfbox.process.types.ConditionItemTypeType getType()
    {
        return this._type;
    } //-- workflow.xwfbox.process.types.ConditionItemTypeType getType() 

    /**
     * Method removeAllConditionItem
     * 
     */
    public void removeAllConditionItem()
    {
        _items.removeAllElements();
    } //-- void removeAllConditionItem() 

    /**
     * Method removeConditionItem
     * 
     * 
     * 
     * @param index
     * @return ConditionItem
     */
    public workflow.xwfbox.process.ConditionItem removeConditionItem(int index)
    {
        java.lang.Object obj = _items.elementAt(index);
        _items.removeElementAt(index);
        return (workflow.xwfbox.process.ConditionItem) obj;
    } //-- workflow.xwfbox.process.ConditionItem removeConditionItem(int) 

    /**
     * Method setConditionItem
     * 
     * 
     * 
     * @param index
     * @param vConditionItem
     */
    public void setConditionItem(int index, workflow.xwfbox.process.ConditionItem vConditionItem)
        throws java.lang.IndexOutOfBoundsException
    {
        //-- check bounds for index
        if ((index < 0) || (index > _items.size())) {
            throw new IndexOutOfBoundsException();
        }
        _items.setElementAt(vConditionItem, index);
    } //-- void setConditionItem(int, workflow.xwfbox.process.ConditionItem) 

    /**
     * Method setConditionItem
     * 
     * 
     * 
     * @param conditionItemArray
     */
    public void setConditionItem(workflow.xwfbox.process.ConditionItem[] conditionItemArray)
    {
        //-- copy array
        _items.removeAllElements();
        for (int i = 0; i < conditionItemArray.length; i++) {
            _items.addElement(conditionItemArray[i]);
        }
    } //-- void setConditionItem(workflow.xwfbox.process.ConditionItem) 

    /**
     * Sets the value of field 'content'. The field 'content' has
     * the following description: internal content storage
     * 
     * @param content the value of field 'content'.
     */
    public void setContent(java.lang.String content)
    {
        this._content = content;
    } //-- void setContent(java.lang.String) 

    /**
     * Sets the value of field 'type'.
     * 
     * @param type the value of field 'type'.
     */
    public void setType(workflow.xwfbox.process.types.ConditionItemTypeType type)
    {
        this._type = type;
    } //-- void setType(workflow.xwfbox.process.types.ConditionItemTypeType) 

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -