Project

General

Profile

Bug #3466 » ps1.xml

Daniel Crawl, 08/06/2008 01:05 PM

 
1
<?xml version="1.0" standalone="no"?>
2
<!DOCTYPE entity PUBLIC "-//UC Berkeley//DTD MoML 1//EN"
3
    "http://ptolemy.eecs.berkeley.edu/xml/dtd/MoML_1.dtd">
4
<entity name="ps1" class="ptolemy.actor.TypedCompositeActor">
5
    <property name="_createdBy" class="ptolemy.kernel.attributes.VersionAttribute" value="7.1.devel">
6
    </property>
7
    <property name="ParameterSet" class="ptolemy.actor.parameters.ParameterSet">
8
        <property name="fileOrURL" class="ptolemy.data.expr.FileParameter" value="/Users/crawl/wf/tests/ps1.conf">
9
        </property>
10
        <property name="checkForFileUpdates" class="ptolemy.data.expr.Parameter" value="true">
11
        </property>
12
<property name="KeplerDocumentation" class="ptolemy.vergil.basic.KeplerDocumentationAttribute">
13
<property name="description" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
14
<property name="author" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>Christopher Brooks, contributor: Edward A. Lee</configure></property>
15
<property name="version" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
16
<property name="userLevelDocumentation" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>
17
 An attribute that reads multiple values from a file and sets
18
 corresponding parameters in the container.
19
 The values are in the form:
20
 <pre>
21
 <i>attributeName</i> = <i>value</i>
22
 </pre>
23
 where <code><i>variableName</i></code> is the name of the attribute
24
 in a format suitable for {@link ptolemy.kernel.util.NamedObj#setName(String)}
25
 (i.e., does not contain periods) and  <code><i>value</i></code> is
26
 the expression in the Ptolemy expression language.
27
 Comments are lines that begin with the <code>#</code> character.
28
 Each line in the file is interpreted as a separate assignment.
29

    
30
 <p>The attributes that are created will have the same
31
 visibility as parameters of the container of the attribute.
32
 They are shadowed, however, by parameters of the container.
33
 That is, if the container has a parameter with the same name
34
 as one in the parameter set, the one in the container provides
35
 the value to any observer.</p>
36

    
37
 <p>If the file is modified during execution of a model, by default
38
 this will not be noticed until the next run. If you set the
39
 <i>checkForFileUpdates</i> parameter to <i>true</i>, then
40
 on each prefiring of the enclosing opaque composite actor,
41
 this parameter will check for updates of the file. Otherwise,
42
 it will only check between runs of the model or when the file
43
 name or URL gets changed.</p>
44

    
45
 <p>Note that the order the parameters are created is arbitrary,
46
 this is because we read the file in using java.util.Properties.load(),
47
 which uses a HashMap to store the properties.  We use a Properties.load()
48
 because it provides a nice parser for the files and can read and write
49
 values in both text and XML.</p>
50
    </configure></property>
51
</property>        <property name="entityId" class="org.kepler.moml.NamedObjId" value="urn:lsid:kepler-project.org:actor:529:1">
52
        </property>
53
        <property name="class" class="ptolemy.kernel.util.StringAttribute" value="ptolemy.actor.parameters.ParameterSet">
54
            <property name="id" class="ptolemy.kernel.util.StringAttribute" value="urn:lsid:kepler-project.org:class:1184:1">
55
            </property>
56
        </property>
57
        <property name="semanticType11" class="org.kepler.sms.SemanticType" value="urn:lsid:localhost:onto:2:1#Parameter">
58
        </property>
59
        <property name="_location" class="ptolemy.kernel.util.Location" value="{400, 100}">
60
        </property>
61
    </property>
62
    <property name="_windowProperties" class="ptolemy.actor.gui.WindowPropertiesAttribute" value="{bounds={278, 49, 883, 802}, maximized=false}">
63
    </property>
64
    <property name="_vergilSize" class="ptolemy.actor.gui.SizeAttribute" value="[600, 681]">
65
    </property>
66
    <property name="_vergilZoomFactor" class="ptolemy.data.expr.ExpertParameter" value="1.0">
67
    </property>
68
    <property name="_vergilCenter" class="ptolemy.data.expr.ExpertParameter" value="{300.0, 340.5}">
69
    </property>
70
    <entity name="Open Database Connection" class="org.geon.OpenDBConnection">
71
        <property name="databaseFormat" class="ptolemy.data.expr.StringParameter" value="Oracle">
72
<display name="database format"/>        </property>
73
        <property name="databaseURL" class="ptolemy.data.expr.StringParameter" value="">
74
        </property>
75
        <property name="username" class="ptolemy.data.expr.StringParameter" value="$x">
76
        </property>
77
        <property name="password" class="ptolemy.data.expr.StringParameter" value="">
78
        </property>
79
<property name="KeplerDocumentation" class="ptolemy.vergil.basic.KeplerDocumentationAttribute">
80
<property name="description" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
81
<property name="author" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>efrat jaeger</configure></property>
82
<property name="version" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>null</configure></property>
83
<property name="userLevelDocumentation" class="ptolemy.kernel.util.ConfigurableAttribute"><configure><p>The OpenDatabaseConnection actor opens a database connection using the specified database format and URL, username, and password. Once a  database connection has been established, the actor outputs a reference to the connection. Actors downstream in the workflow can use this reference to access the database.</p></configure></property>
84
<property name="port:dbcon" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>An output port that broadcasts a reference to the established database connection. Other actors can use this reference to interact with the database.</configure></property>
85
<property name="prop:password" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>Database password.</configure></property>
86
<property name="prop:databaseURL" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>The location of the database (e.g. jdbc:db2://compute1.sdsc.geongrid.org:50000/testpgap)</configure></property>
87
<property name="prop:databaseFormat" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>The type of database to access (e.g. Oracle, MySQL, etc)</configure></property>
88
<property name="prop:username" class="ptolemy.kernel.util.ConfigurableAttribute"><configure>Database user name.</configure></property>
89
</property>        <property name="entityId" class="org.kepler.moml.NamedObjId" value="urn:lsid:kepler-project.org:actor:155:1">
90
        </property>
91
        <property name="class" class="ptolemy.kernel.util.StringAttribute" value="org.geon.OpenDBConnection">
92
            <property name="id" class="ptolemy.kernel.util.StringAttribute" value="urn:lsid:kepler-project.org:class:1013:1">
93
            </property>
94
        </property>
95
        <property name="semanticType00" class="org.kepler.sms.SemanticType" value="urn:lsid:localhost:onto:1:1#DatabaseExternalInputActor">
96
        </property>
97
        <property name="semanticType11" class="org.kepler.sms.SemanticType" value="urn:lsid:localhost:onto:2:1#DatabaseInputFunction">
98
        </property>
99
        <property name="_location" class="ptolemy.kernel.util.Location" value="[170.0, 220.0]">
100
        </property>
101
    </entity>
102
</entity>
(1-1/2)