Package blackberry.core

Examples of blackberry.core.ScriptableFunctionBase


     * Implements ScriptableFunctionBase to retrieve a list of services of interest.
     *
     * @return the list of services implemented as items in the ServiceObject array.
     */
    public static ScriptableFunction createGetServiceListFunction() {
        return new ScriptableFunctionBase() {

            public Object execute( final Object thiz, final Object[] args ) {
                return IdentityFunctions.getServiceList();
            };

View Full Code Here


        }
        return UNDEFINED;
    }

    private ScriptableFunction createFindMethod() {
        return new ScriptableFunctionBase() {

            /**
             * @see blackberry.core.ScriptableFunctionBase#execute(java.lang.Object, java.lang.Object[])
             */
            public Object execute( Object thiz, Object[] args ) throws Exception {
View Full Code Here

        _save = new AppointmentSaveScriptableFunction();
        return _save;
    }

    private ScriptableFunction createRemoveMethod() {
        return new ScriptableFunctionBase() {
            public Object execute( Object innerThiz, Object[] innerArgs ) throws Exception {
                if( _event == null ) {
                    throw new PIMException( "PIMItem not found." );
                }
View Full Code Here

        _fields.put( FUNCTION_GETURLPARAMETERBYINDEX, createGetURLParameterByIndexFunction() );
    }

    private ScriptableFunctionBase createGetURLParameterFunction() {

        return new ScriptableFunctionBase() {

            protected Object execute( Object thiz, Object[] args ) throws Exception {
                String key = ( args[ 0 ] ).toString();

                return ( _parameters == null || _parameters.get( key ) == null ) ? UNDEFINED : _parameters.get( key );
View Full Code Here

        };
    }

    private ScriptableFunctionBase createGetURLParameterByIndexFunction() {

        return new ScriptableFunctionBase() {

            protected Object execute( Object thiz, Object[] args ) throws Exception {
                int index = ( (Integer) args[ 0 ] ).intValue();

                return ( _keys == null || index < 0 || index >= _keys.size() ) ? UNDEFINED : _parameters.get( _keys
View Full Code Here

TOP

Related Classes of blackberry.core.ScriptableFunctionBase

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.