This file is indexed.

/usr/lib/lv2/patch.lv2/patch.ttl is in lv2-dev 1.0.0~dfsg2-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
@prefix dcs:   <http://ontologi.es/doap-changeset#> .
@prefix doap:  <http://usefulinc.com/ns/doap#> .
@prefix foaf:  <http://xmlns.com/foaf/0.1/> .
@prefix lv2:   <http://lv2plug.in/ns/lv2core#> .
@prefix owl:   <http://www.w3.org/2002/07/owl#> .
@prefix patch: <http://lv2plug.in/ns/ext/patch#> .
@prefix rdf:   <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs:  <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd:   <http://www.w3.org/2001/XMLSchema#> .

<http://lv2plug.in/ns/ext/patch>
	a lv2:Specification ;
	rdfs:seeAlso <patch.h> ,
		<../../meta/meta.ttl> ;
	doap:created "2012-02-09" ;
	doap:license <http://opensource.org/licenses/isc> ;
	doap:developer <http://drobilla.net/drobilla#me> ;
	doap:name "LV2 Patch" ;
	doap:release [
		doap:revision "1.0" ;
		doap:created "2012-04-17" ;
		doap:file-release <http://lv2plug.in/spec/lv2-1.0.0.tar.bz2> ;
		dcs:blame <http://drobilla.net/drobilla#me> ;
		dcs:changeset [
			dcs:item [
				rdfs:label "Initial release."
			]
		]
	] ;
	doap:shortdesc "Messages for accessing and manipulating properties." ;
	lv2:documentation """
<p>This vocabulary defines messages which can be used to access and manipulate
properties.  It is designed to provide a dynamic control interface for LV2
plugins, but is useful in many contexts.</p>

<p>The main feature of this design is that the messages themselves are
described in the same format as the data they work with.  In particular,
messages can be serialised as an <a
href="http://lv2plug.in/ns/ext/atom#Object">LV2 Object</a> or in Turtle (or any
other RDF serialisation).</p>

<p>The idea behind using a property-based interface for control is to prevent
an an explosion of message types.  Instead of a custom message for each action,
control is achieved via manipulating properties (which are likely already
defined for other reasons).  Note, however, that this is purely conceptual;
there is no requirement that the receiver actually implement a store of
resources with properties.</p>

<p>For example, consider an object that can blink.  Rather than define a
specific interface to control this (e.g. <code>obj.start_blinking();
obj.stop_blinking()</code>), set a <q>blinking</q> property to true or false
(e.g. <code>obj.set(blinking, true)</code>) to achieve the desired behaviour.
One benefit of this approach is that a persistent state model is available
<q>for free</q>: simply serialise the <q>blinking</q> property.</p>

<p>This specification is strictly metadata and does not define any binary
mechanism, though it can be completely expressed by standard types in the <a
href="http://lv2plug.in/ns/ext/atom">LV2 Atom</a> extension.  Thus, hosts can
be expected to be capable of transmitting it between plugins, or between a
plugin and its UI, making it a good choice for advanced plugin control.</p>
""" .

patch:Ack
	a rdfs:Class ;
	rdfs:subClassOf patch:Response ;
	rdfs:label "Ack" ;
	lv2:documentation """
<p>An acknowledgement that a request has been successfully processed.  This is
returned as a reply when a specific reply type is not necessary or
appropriate.</p>
""" .

patch:Delete
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ;
	rdfs:label "Delete" ;
	lv2:documentation """
<p>Request the subject(s) be deleted.</p>
""" .

patch:Error
	a rdfs:Class ;
	rdfs:subClassOf patch:Response ;
	rdfs:label "Error" ;
	lv2:documentation """
<p>A response indicating an error processing a request.</p>
""" .

patch:Get
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ;
	rdfs:label "Get" ;
	lv2:documentation """
<p>Request a description of the subject.</p>

<p>The detail of the response is not specified, it may be a flat description of
all the properties of the subject, or a more expressive description with
several subjects.  A good choice is a <q><a
href="http://www.w3.org/Submission/CBD/">concise bounded description</a></q>,
i.e. a description which recursively includes all properties with blank node
values.</p>

<p>The response should have the same patch:subject property as the request, and
a patch:body that is a description of that subject.  For example:</p>
<pre class="turtle-code">
&lt;get-request&gt;
    a patch:Get ;
    patch:subject &lt;something&gt; .
</pre>

<p>Could result in:</p>
<pre class="turtle-code">
[]
    a patch:Response ;
    patch:request &lt;get-request&gt; ;
    patch:subject &lt;something&gt; ;
    patch:body [
        eg:name "Something" ;
        eg:ratio 1.6180339887 ;
    ] .
</pre>

<p>Note the use of blank nodes is not required; the value of patch:body may be
the actual resource node.  Depending on the transport and syntax used this may
be preferable.  However, the patch:subject property is required regardless.  For
example, the same response could be written:</p>

<pre class="turtle-code">
&lt;something&gt;
    eg:name "Something" ;
    eg:ratio 1.6180339887 .

[]
    a patch:Response ;
    patch:request &lt;get-request&gt; ;
    patch:subject &lt;something&gt; ;
    patch:body &lt;something&gt; .
</pre>
""" .

patch:Insert
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ;
	rdfs:label "Insert" ;
	rdfs:subClassOf [
		a owl:Restriction ;
		owl:cardinality 1 ;
		owl:onProperty patch:subject
	] ;
	lv2:documentation """
<p>Insert the patch:body at patch:subject.  If the subject does not exist, it is
created.  If the subject does already exist, it is added to.  This request only
adds properties, it never removes them.  The user must take care that multiple
values are not set for properties which should only have one value.</p>
""" .

patch:Message
	a rdfs:Class ;
	rdfs:label "Message" .

patch:Move
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ;
	rdfs:label "Move" ;
	rdfs:subClassOf [
		a owl:Restriction ;
		owl:cardinality 1 ;
		owl:onProperty patch:subject
	] , [
		a owl:Restriction ;
		owl:cardinality 1 ;
		owl:onProperty patch:destination
	] ;
	lv2:documentation """
<p>Move the patch:subject to patch:destination.  After this, patch:destination has
the description patch:subject had prior to this request's execution, and
patch:subject does not exist any more.It is an error if the subject does not
exist or the destination already exists.</p>
""" .

patch:Patch
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ,
	[
		a owl:Restriction ;
		owl:minCardinality 1 ;
		owl:onProperty patch:subject
	] ;
	lv2:documentation """
<p>A method for modifying the properties of an object.</p>

<p>This method always has at least one patch:subject, and exactly one patch:add
and patch:remove property.  The value of patch:add and patch:remove are nodes
which have the properties to add or remove from the subject(s), respectively.
The special value patch:wildcard may be used as the value of a remove property
to remove all properties with the given predicate.  For example:</p>

<pre class="turtle-code">
[]
    a patch:Patch ;
    patch:subject &lt;something&gt; ;
    patch:add [
        eg:name "New name" ;
        eg:age 42 ;
    ] ;
    patch:remove [
        eg:name "Old name" ;
        eg:age patch:wildcard ;  # Remove all old eg:age properties
    ] .
</pre>
""" .

patch:Put
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ;
	rdfs:label "Put" ;
	rdfs:subClassOf [
		a owl:Restriction ;
		owl:cardinality 1 ;
		owl:onProperty patch:subject
	] ;
	lv2:documentation """
<p>Put the patch:body as the patch:subject.  If the subject does not already exist,
it is created.  If the subject does already exist, the patch:body is considered
an updated version of it, and the previous version is replaced.</p>
""" .

patch:Request
	a rdfs:Class ;
	rdfs:label "Request" ;
	rdfs:subClassOf patch:Message ;
	lv2:documentation """
<p>A request.  A request may have a patch:subject property, which indicates which
resource the request applies to.  The subject may be omitted in contexts where
it is implicit (e.g. the recipient is the subject).</p>
""" .

patch:Response
	a rdfs:Class ;
	rdfs:subClassOf patch:Message ;
	rdfs:label "Response" ;
	lv2:documentation """
<p>A response to a method.</p>
""" .

patch:Set
	a rdfs:Class ;
	rdfs:subClassOf patch:Request ,
	[
		a owl:Restriction ;
		owl:cardinality 1 ;
		owl:onProperty patch:body
	] ;
	lv2:documentation """
<p>A method for setting properties of an object to unique values.</p>

<p>This is a simplified version of patch:Patch which only makes sense for
properties which have at most one value.  This method always has at least one
patch:subject, and exactly one patch:add property.  All the properties of the
value of patch:add are set on the subject, with all old values for those
properties removed.  For example:</p>

<pre class="turtle-code">
[]
    a patch:Set ;
    patch:subject &lt;something&gt; ;
    patch:body [
        eg:name "New name" ;
        eg:age 42 ;
    ] .
</pre>

<p>This method is equivalent to a patch:Patch where the patch:remove value has
every property of patch:add but with wildcard values.  For example, the above
patch is equivalent to:</p>
<pre class="turtle-code">
[]
    a patch:Patch ;
    patch:subject &lt;something&gt; ;
    patch:add [
        eg:name "New name" ;
        eg:age 42 ;
    ] ;
    patch:remove [
        eg:name patch:wildcard ;
        eg:age patch:wildcard ;
    ] ;
</pre>
""" .

patch:add
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Message .

patch:body
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Message ;
	lv2:documentation """
<p>The body of a message.</p>

<p>The details of this property's value depend on the type of message it is a
part of.</p>
""" .

patch:destination
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Message .

patch:request
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Response ;
	rdfs:range patch:Request ;
	lv2:documentation """
<p>The request this is a response to.</p>
""" .

patch:subject
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Message .

patch:remove
	a rdf:Property ,
		owl:ObjectProperty ,
		owl:FunctionalProperty ;
	rdfs:domain patch:Message .

patch:wildcard
	a rdfs:Resource ;
	rdfs:comment """
A wildcard which matches any resource.  This makes it possible to describe the removal of all values for a given property.
""" .