01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */
17: package org.apache.jetspeed.page.impl;
18:
19: /**
20: * A transactioned operation is a single Page Manager DML operation that was applied
21: * to the OJB cache. Im finding that OJB is not properly synchronizing its cache
22: * upon rollback of database transactions. This code may not be needed in future
23: * versions of OJB which have fixed this bug.
24: *
25: * @author <a href="mailto:taylor@apache.org">David Sean Taylor</a>
26: * @version $Id: $
27: */
28: public class TransactionedOperation {
29: public static final int ADD_OPERATION = 0;
30: public static final int UPDATE_OPERATION = 1;
31: private String path;
32: private int transactionType;
33:
34: public TransactionedOperation(String path, int type) {
35: this .path = path;
36: this .transactionType = type;
37: }
38:
39: public String getPath() {
40: return path;
41: }
42:
43: public void setPath(String path) {
44: this .path = path;
45: }
46:
47: public int getTransactionType() {
48: return transactionType;
49: }
50:
51: public void setTransactionType(int transactionType) {
52: this.transactionType = transactionType;
53: }
54: }
|