EMMA Coverage Report (generated Tue Jul 10 07:50:22 IST 2012)
[all classes][org.wso2.siddhi.query.api]

COVERAGE SUMMARY FOR SOURCE FILE [QueryFactory.java]

nameclass, %method, %block, %line, %
QueryFactory.java100% (1/1)82%  (9/11)81%  (52/64)82%  (9/11)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class QueryFactory100% (1/1)82%  (9/11)81%  (52/64)82%  (9/11)
QueryFactory (): void 0%   (0/1)0%   (0/3)0%   (0/1)
joinStream (SingleStream, JoinStream$Type, SingleStream): Stream 0%   (0/1)0%   (0/9)0%   (0/1)
createQuery (): Query 100% (1/1)100% (4/4)100% (1/1)
createStreamDefinition (): StreamDefinition 100% (1/1)100% (4/4)100% (1/1)
inputStream (String): SingleStream 100% (1/1)100% (6/6)100% (1/1)
inputStream (String, String): SingleStream 100% (1/1)100% (6/6)100% (1/1)
joinStream (SingleStream, JoinStream$Type, SingleStream, Condition): Stream 100% (1/1)100% (9/9)100% (1/1)
joinStream (SingleStream, JoinStream$Type, SingleStream, Condition, JoinStrea... 100% (1/1)100% (9/9)100% (1/1)
outputProjector (): Projector 100% (1/1)100% (4/4)100% (1/1)
patternStream (PatternElement): PatternStream 100% (1/1)100% (5/5)100% (1/1)
sequenceStream (SequenceElement): SequenceStream 100% (1/1)100% (5/5)100% (1/1)

1/*
2*  Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
3*
4*  WSO2 Inc. licenses this file to you under the Apache License,
5*  Version 2.0 (the "License"); you may not use this file except
6*  in compliance with the License.
7*  You may obtain a copy of the License at
8*
9*    http://www.apache.org/licenses/LICENSE-2.0
10*
11* Unless required by applicable law or agreed to in writing,
12* software distributed under the License is distributed on an
13* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14* KIND, either express or implied.  See the License for the
15* specific language governing permissions and limitations
16* under the License.
17*/
18package org.wso2.siddhi.query.api;
19 
20import org.wso2.siddhi.query.api.condition.Condition;
21import org.wso2.siddhi.query.api.definition.StreamDefinition;
22import org.wso2.siddhi.query.api.query.Query;
23import org.wso2.siddhi.query.api.query.projection.Projector;
24import org.wso2.siddhi.query.api.stream.JoinStream;
25import org.wso2.siddhi.query.api.stream.SingleStream;
26import org.wso2.siddhi.query.api.stream.Stream;
27import org.wso2.siddhi.query.api.stream.pattern.PatternStream;
28import org.wso2.siddhi.query.api.stream.pattern.element.PatternElement;
29import org.wso2.siddhi.query.api.stream.sequence.SequenceStream;
30import org.wso2.siddhi.query.api.stream.sequence.element.SequenceElement;
31 
32public abstract class QueryFactory {
33 
34    public static Query createQuery() {
35        return new Query();
36    }
37 
38    public static StreamDefinition createStreamDefinition() {
39        return new StreamDefinition();
40    }
41 
42    public static SingleStream inputStream(String streamId) {
43        return new SingleStream(streamId, streamId);
44    }
45 
46    public static Projector outputProjector() {
47        return new Projector();
48    }
49 
50    public static Stream joinStream(SingleStream leftStream, JoinStream.Type type,
51                                    SingleStream rightStream,
52                                    Condition onCompare) {
53        return new JoinStream(leftStream, type, rightStream, onCompare, JoinStream.EventTrigger.ALL);
54    }
55 
56    public static Stream joinStream(SingleStream leftStream, JoinStream.Type type,
57                                    SingleStream rightStream) {
58        return new JoinStream(leftStream, type, rightStream, null, JoinStream.EventTrigger.ALL);
59    }
60 
61    public static Stream joinStream(SingleStream leftStream, JoinStream.Type type,
62                                    SingleStream rightStream,
63                                    Condition onCompare, JoinStream.EventTrigger trigger) {
64        return new JoinStream(leftStream, type, rightStream, onCompare, trigger);
65    }
66 
67    public static SingleStream inputStream(String streamReferenceId, String streamId) {
68        return new SingleStream(streamReferenceId, streamId);
69 
70    }
71 
72    public static PatternStream patternStream(PatternElement patternElement) {
73        return new PatternStream(patternElement);
74    }
75 
76    public static SequenceStream sequenceStream(SequenceElement sequenceElement) {
77        return new SequenceStream(sequenceElement);
78    }
79}

[all classes][org.wso2.siddhi.query.api]
EMMA 2.1.5320 (stable) (C) Vladimir Roubtsov