Package org.apache.empire.exceptions

Examples of org.apache.empire.exceptions.ObjectNotValidException


     */
    @Override
    public int addColumnDesc(Element parent)
    {
        if (!isValid())
            throw new ObjectNotValidException(this);
        // Add Field Description
        int count = 0;
        List<DBColumn> columns = rowset.getColumns();
        for (int i = 0; i < columns.size(); i++)
        { // Add Field
View Full Code Here


     */
    @Override
    public int addRowValues(Element parent)
    {
        if (!isValid())
            throw new ObjectNotValidException(this);
        // set row key
        DBColumn[] keyColumns = rowset.getKeyColumns();
        if (keyColumns != null && keyColumns.length > 0)
        { // key exits
            if (keyColumns.length > 1)
View Full Code Here

     */
    @Override
    public Document getXmlDocument()
    {
        if (!isValid())
            throw new ObjectNotValidException(this);
        // Create Document
        DBXmlDictionary xmlDic = getXmlDictionary();
        Element root = XMLUtil.createDocument(xmlDic.getRowSetElementName());
        if (rowset.getName() != null)
            root.setAttribute("name", rowset.getName());
View Full Code Here

    public boolean skipRows(int count)
    {
        try
        {   // Check Recordset
            if (rset == null)
                throw new ObjectNotValidException(this);
            // Forward only cursor?
            int type = rset.getType();
            if (type == ResultSet.TYPE_FORWARD_ONLY)
            {
                if (count < 0)
View Full Code Here

    public boolean moveNext()
    {
        try
        {   // Check Recordset
            if (rset == null)
                throw new ObjectNotValidException(this);
            // Move Next
            if (rset.next() == false)
            { // Close recordset automatically after last record
                close();
                return false;
View Full Code Here

    public <C extends Collection<T>, T> C getBeanList(C c, Class<T> t, int maxCount)
    {
        // Check Recordset
        if (rset == null)
        {   // Resultset not available
            throw new ObjectNotValidException(this);
        }
        // Query List
        try
        {
            // Check whether we can use a constructor
View Full Code Here

     */
    @Override
    public int addColumnDesc(Element parent)
    {
        if (colList == null)
            throw new ObjectNotValidException(this);
        // Add Field Description
        for (int i = 0; i < colList.length; i++)
            colList[i].addXml(parent, 0);
        // return count
        return colList.length;
View Full Code Here

     */
    @Override
    public int addRowValues(Element parent)
    {
        if (rset == null)
            throw new ObjectNotValidException(this);
        // Add all children
        for (int i = 0; i < colList.length; i++)
        { // Read all
            String name = colList[i].getName();
            String idColumnAttr = getXmlDictionary().getRowIdColumnAttribute();
View Full Code Here

        {
            // Check position
            if (curCount >= maxCount)
                return false;
            if (rset == null)
                throw new ObjectNotValidException(this);
            // Check next Record
            if (getCurrent == true)
            {
                getCurrent = false;
                hasCurrent = moveNext();
View Full Code Here

    {
        T bean = createBean();
        if (bean==null)
        {   // Must have an action error set!
            if (!hasActionError())
                setActionError(new ObjectNotValidException(beanSupport.getRecordPropertyName()));
            return doCancel();
        }
        beanSupport.setData(bean);
        return INPUT;
    }
View Full Code Here

TOP

Related Classes of org.apache.empire.exceptions.ObjectNotValidException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.