OBEFilter.java :  » Workflow-Engines » obe-1.0 » org » obe » client » api » model » Java Open Source

Java Open Source » Workflow Engines » obe 1.0 
obe 1.0 » org » obe » client » api » model » OBEFilter.java
package org.obe.client.api.model;

import java.util.Date;
import org.wfmc.wapi.WMFilter;

/**
 * Filter class that supports an ORDER BY clause and the ability to limit the
 * number of rows returned.
 *
 * @author Adrian Price
 */
public class OBEFilter extends WMFilter {
    private final String _orderBy;
    private final int _startRow;
    private final int _maxRows;

    public OBEFilter(String attributeName, int comparison,
        Boolean attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        boolean attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        Date attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        Double attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        double attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        Integer attributeValue, String orderBy, int startAt, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startAt;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        int attributeValue, String orderBy, int startRow, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startRow;
        _maxRows = maxRows;
    }

    public OBEFilter(String attributeName, int comparison,
        String attributeValue, String orderBy, int startRow, int maxRows) {

        super(attributeName, comparison, attributeValue);
        _orderBy = orderBy;
        _startRow = startRow;
        _maxRows = maxRows;
    }

    public OBEFilter(String sql, String orderBy, int startRow, int maxRows) {
        super(sql);
        _orderBy = orderBy;
        _startRow = startRow;
        _maxRows = maxRows;
    }

    public String getOrderBy() {
        return _orderBy;
    }

    public int getStartRow() {
        return _startRow;
    }

    public int getMaxRows() {
        return _maxRows;
    }
}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.