001    /*
002    // $Id: //open/mondrian/src/main/mondrian/xmla/XmlaRequest.java#8 $
003    // This software is subject to the terms of the Common Public License
004    // Agreement, available at the following URL:
005    // http://www.opensource.org/licenses/cpl.html.
006    // Copyright (C) 2005-2007 Julian Hyde
007    // All Rights Reserved.
008    // You must accept the terms of that agreement to use this software.
009    */
010    package mondrian.xmla;
011    
012    import mondrian.olap.Role;
013    import java.util.Map;
014    import java.util.List;
015    
016    /**
017     * XML/A request interface.
018     *
019     * @author Gang Chen
020     * @version $Id: //open/mondrian/src/main/mondrian/xmla/XmlaRequest.java#8 $
021     */
022    public interface XmlaRequest {
023    
024        /**
025         * Indicate DISCOVER or EXECUTE method.
026         */
027        int getMethod();
028    
029        /**
030         * Properties of XML/A request.
031         */
032        Map<String, String> getProperties();
033    
034        /**
035         * Restrictions of DISCOVER method.
036         *
037         * <p>If the value is a list of strings, the restriction passes if the
038         * column has one of the values.
039         */
040        Map<String, Object> getRestrictions();
041    
042        /**
043         * Statement of EXECUTE method.
044         */
045        String getStatement();
046    
047        /**
048         * Role name binds with this XML/A reqeust. Maybe null.
049         */
050        String getRoleName();
051    
052        /**
053         * Role binds with this XML/A reqeust. Maybe null.
054         */
055        Role getRole();
056    
057        /**
058         * Request type of DISCOVER method.
059         */
060        String getRequestType();
061    
062        /**
063         * Indicate whether statement is a drill through statement of
064         * EXECUTE method.
065         */
066        boolean isDrillThrough();
067    
068        /**
069         * Drill through option: max returning rows of query.
070         *
071         * Value -1 means this option isn't provided.
072         */
073        int drillThroughMaxRows();
074    
075        /**
076         * Drill through option: first returning row of query.
077         *
078         * Value -1 means this option isn't provided.
079         */
080        int drillThroughFirstRowset();
081    
082    }
083    
084    // End XmlaRequest.java