]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.db.procore/src/org/simantics/db/procore/cluster/ClusterChangeSetI.java
Fail safe import fixes made by Antti
[simantics/platform.git] / bundles / org.simantics.db.procore / src / org / simantics / db / procore / cluster / ClusterChangeSetI.java
1 /*******************************************************************************
2  * Copyright (c) 2007, 2010 Association for Decentralized Information Management
3  * in Industry THTH ry.
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License v1.0
6  * which accompanies this distribution, and is available at
7  * http://www.eclipse.org/legal/epl-v10.html
8  *
9  * Contributors:
10  *     VTT Technical Research Centre of Finland - initial API and implementation
11  *******************************************************************************/
12 package org.simantics.db.procore.cluster;
13
14 import org.simantics.db.service.ClusterUID;
15
16
17 public interface ClusterChangeSetI {
18     enum OperationEnum {
19         Null,
20         CreateResource,
21         AddRelation,
22         RemoveRelation,
23         SetValue,
24         DeleteValue,
25         ModifyValue,
26         EndOf;
27     }
28     public static class Operation {
29            ClusterChangeSet.IteratorI iterator; // Position of the iteration. Do not mess with this.
30            public OperationEnum type;
31            public int count; // number of arguments
32            public short resourceIndex;
33            public short predicateIndex;
34            public ClusterUID predicateCluster;
35            public short objectIndex;
36            public ClusterUID objectCluster;
37            public long valueOffset;
38            public int valueSize;
39            public byte[] valueData; // The actual byte table where value data is. Do not mess with this.
40            public int valueStart; // Start of value in valueData.
41            public long cs;
42            public long prevCs;
43     };
44     public void getNextOperation(Operation operation); // Skips unasked arguments.
45         public ClusterUID getClusterUID();
46 }