Package org.pentaho.platform.scheduler2.quartz

Examples of org.pentaho.platform.scheduler2.quartz.QuartzScheduler


    ListParamValue listValue = new ListParamValue();
    listValue.add( "testListVal0" );
    listValue.add( "testListVal1" );

    MapParamValue mapValue = new MapParamValue();
    mapValue.put( "testMapKey0", "testMapVal0" );
    mapValue.put( "testMapKey1", "testMapVal1" );

    privateParams.put( "stringParam", new StringParamValue( "testStringValue" ) );
    privateParams.put( "listParam", listValue );
    privateParams.put( "mapParam", mapValue );
View Full Code Here


  public void testJaxbSafeMap() throws JAXBException {
    HashMap<String, ParamValue> params = new HashMap<String, ParamValue>();
    ListParamValue listValue = new ListParamValue();
    listValue.add( "testListVal0" );
    listValue.add( "testListVal1" );
    MapParamValue mapValue = new MapParamValue();
    mapValue.put( "testMapValueKey", "testMapVal" );

    params.put( "testStringkey", new StringParamValue( "testStringVal" ) );
    params.put( "testListKey", listValue );
    params.put( "testMapKey", mapValue );
    JaxBSafeMap map = new JaxBSafeMap( params );
View Full Code Here

    Assert.assertEquals( "testMapVal", unmarshalled.entry.get( 2 ).getMapValue().get( "testMapValueKey" ) );
  }

  @Test
  public void testParamValue() throws JAXBException {
    ParamValue val = new StringParamValue( "testval" );

    ParamValue unmarshalled = JaxBUtil.outin( val, StringParamValue.class );
    Assert.assertEquals( "testval", unmarshalled.toString() );
  }
View Full Code Here

    MyAction.executed = false;
    MyAction.staticStringParam = null;

    jobParams = new HashMap<String, ParamValue>();
    jobParams.put( "stringParam", new StringParamValue( "testStringValue" ) );

    RUN_ONCE_IN_2_SECS = JobTrigger.ONCE_NOW;
    RUN_ONCE_IN_2_SECS.setStartTime( new Date( System.currentTimeMillis() + 2000L ) );

    RUN_ONCE_IN_3_SECS = JobTrigger.ONCE_NOW;
View Full Code Here

    MapParamValue mapValue = new MapParamValue();
    mapValue.put( "testMapKey0", "testMapVal0" );
    mapValue.put( "testMapKey1", "testMapVal1" );

    privateParams.put( "stringParam", new StringParamValue( "testStringValue" ) );
    privateParams.put( "listParam", listValue );
    privateParams.put( "mapParam", mapValue );

    return privateParams;
  }
View Full Code Here

    jobTrigger.setMinuteRecurrence( new IncrementalRecurrence( startingMinute, 5 ) );
    jobTrigger.setHourlyRecurrence( (ITimeRecurrence) null );
    System.out.println( jobTrigger.toString() );

    HashMap<String, ParamValue> newJobParams = new HashMap<String, ParamValue>( jobParams );
    newJobParams.put( "newKey", new StringParamValue( "" ) );
    schedulerSvc.updateJobToUseComplexTrigger( jobId, newJobParams, jobTrigger );

    Assert.assertEquals( 1, schedulerSvc.getJobs().length );
    Job job = schedulerSvc.getJobs()[0];
    jobTrigger = (ComplexJobTrigger) job.getJobTrigger();
View Full Code Here

    jobTrigger.setRepeatInterval( 40 );
    jobTrigger.setRepeatCount( 50 );
    System.out.println( jobTrigger.toString() );

    HashMap<String, ParamValue> newJobParams = new HashMap<String, ParamValue>( jobParams );
    newJobParams.put( "newKey", new StringParamValue( "" ) );
    schedulerSvc.updateJobToUseSimpleTrigger( jobId, newJobParams, jobTrigger );

    Assert.assertEquals( 1, schedulerSvc.getJobs().length );
    Job job = schedulerSvc.getJobs()[0];
    jobTrigger = (SimpleJobTrigger) job.getJobTrigger();
View Full Code Here

    listValue.add( "testListVal0" );
    listValue.add( "testListVal1" );
    MapParamValue mapValue = new MapParamValue();
    mapValue.put( "testMapValueKey", "testMapVal" );

    params.put( "testStringkey", new StringParamValue( "testStringVal" ) );
    params.put( "testListKey", listValue );
    params.put( "testMapKey", mapValue );
    JaxBSafeMap map = new JaxBSafeMap( params );

    JaxBSafeMap unmarshalled = JaxBUtil.outin( map, JaxBSafeMap.class, JaxBSafeEntry.class, StringParamValue.class );
View Full Code Here

    Assert.assertEquals( "testMapVal", unmarshalled.entry.get( 2 ).getMapValue().get( "testMapValueKey" ) );
  }

  @Test
  public void testParamValue() throws JAXBException {
    ParamValue val = new StringParamValue( "testval" );

    ParamValue unmarshalled = JaxBUtil.outin( val, StringParamValue.class );
    Assert.assertEquals( "testval", unmarshalled.toString() );
  }
View Full Code Here

    job.schedulableClass = "test.schedulable.class";
    job.state = Job.JobState.COMPLETE;
    job.userName = "testUsername";

    HashMap<String, ParamValue> params = new HashMap<String, ParamValue>();
    params.put( "testStringkey", new StringParamValue( "testStringVal" ) );

    JaxBSafeMap safeMap = new JaxBSafeMap( params );
    job.jobParams = safeMap;

    JobAdapter.JaxbSafeJob unmarshalledJob = JaxBUtil.outin( job, JobAdapter.JaxbSafeJob.class );
View Full Code Here

TOP

Related Classes of org.pentaho.platform.scheduler2.quartz.QuartzScheduler

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.