Author: clement
Date: Sat Apr 21 11:01:50 2012
New Revision: 1328634
URL: http://svn.apache.org/viewvc?rev=1328634&view=rev
Log:
Update to latest iPOJO API
Modified:
felix/trunk/ipojo/handler/transaction/pom.xml
felix/trunk/ipojo/handler/transaction/src/main/java/org/apache/felix/ipojo/transaction/TransactionHandler.java
Modified: felix/trunk/ipojo/handler/transaction/pom.xml
URL:
http://svn.apache.org/viewvc/felix/trunk/ipojo/handler/transaction/pom.xml?rev=1328634&r1=1328633&r2=1328634&view=diff
==============================================================================
--- felix/trunk/ipojo/handler/transaction/pom.xml (original)
+++ felix/trunk/ipojo/handler/transaction/pom.xml Sat Apr 21 11:01:50 2012
@@ -49,7 +49,7 @@
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-ipojo-plugin</artifactId>
- <version>${project.version}</version>
+ <version>1.8.4</version>
<executions>
<execution>
<goals>
@@ -100,7 +100,7 @@
<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.ipojo</artifactId>
- <version>${project.version}</version>
+ <version>1.9.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.apache.felix</groupId>
Modified:
felix/trunk/ipojo/handler/transaction/src/main/java/org/apache/felix/ipojo/transaction/TransactionHandler.java
URL:
http://svn.apache.org/viewvc/felix/trunk/ipojo/handler/transaction/src/main/java/org/apache/felix/ipojo/transaction/TransactionHandler.java?rev=1328634&r1=1328633&r2=1328634&view=diff
==============================================================================
---
felix/trunk/ipojo/handler/transaction/src/main/java/org/apache/felix/ipojo/transaction/TransactionHandler.java
(original)
+++
felix/trunk/ipojo/handler/transaction/src/main/java/org/apache/felix/ipojo/transaction/TransactionHandler.java
Sat Apr 21 11:01:50 2012
@@ -44,12 +44,12 @@ public class TransactionHandler extends
private static final String NOROLLBACKFOR_ATTRIBUTE = "norollbackfor";
- public static final int DEFAULT_PROPAGATION =
TransactionnalMethod.REQUIRES;
+ public static final int DEFAULT_PROPAGATION = TransactionalMethod.REQUIRES;
private TransactionManager m_transactionManager; // Service Dependency
- private List<TransactionnalMethod> m_methods = new
ArrayList<TransactionnalMethod>();
+ private List<TransactionalMethod> m_methods = new
ArrayList<TransactionalMethod>();
private Callback m_onRollback;
@@ -103,11 +103,11 @@ public class TransactionHandler extends
String eorb = sub[i].getAttribute(EXCEPTIONONROLLBACK_ATTRIBUTE);
if (method == null) {
- throw new ConfigurationException("A transactionnal element
must specified the method attribute");
+ throw new ConfigurationException("A transactional element must
specified the method attribute");
}
MethodMetadata meta = this.getPojoMetadata().getMethod(method);
if (meta == null) {
- throw new ConfigurationException("A transactionnal method is
not in the pojo class : " + method);
+ throw new ConfigurationException("A transactional method is
not in the pojo class : " + method);
}
int timeout = 0;
@@ -130,7 +130,7 @@ public class TransactionHandler extends
exceptionOnRollback = new Boolean(eorb).booleanValue();
}
- TransactionnalMethod tm = new TransactionnalMethod(method,
propagation, timeout, exceptions, exceptionOnRollback, this);
+ TransactionalMethod tm = new TransactionalMethod(method,
propagation, timeout, exceptions, exceptionOnRollback, this);
m_methods.add(tm);
this.getInstanceManager().register(meta, tm);
}
@@ -139,22 +139,22 @@ public class TransactionHandler extends
private int parsePropagation(String propa) throws ConfigurationException {
if (propa.equalsIgnoreCase("requires")) {
- return TransactionnalMethod.REQUIRES;
+ return TransactionalMethod.REQUIRES;
} else if (propa.equalsIgnoreCase("mandatory")){
- return TransactionnalMethod.MANDATORY;
+ return TransactionalMethod.MANDATORY;
} else if (propa.equalsIgnoreCase("notsupported")) {
- return TransactionnalMethod.NOT_SUPPORTED;
+ return TransactionalMethod.NOT_SUPPORTED;
} else if (propa.equalsIgnoreCase("supported")) {
- return TransactionnalMethod.SUPPORTED;
+ return TransactionalMethod.SUPPORTED;
} else if (propa.equalsIgnoreCase("never")) {
- return TransactionnalMethod.NEVER;
+ return TransactionalMethod.NEVER;
} else if (propa.equalsIgnoreCase("requiresnew")) {
- return TransactionnalMethod.REQUIRES_NEW;
+ return TransactionalMethod.REQUIRES_NEW;
}
throw new ConfigurationException("Unknown propgation policy : " +
propa);
@@ -162,7 +162,7 @@ public class TransactionHandler extends
public void start() {
// Set transaction managers.
- for (TransactionnalMethod method : m_methods) {
+ for (TransactionalMethod method : m_methods) {
method.setTransactionManager(m_transactionManager);
}
}
@@ -172,13 +172,13 @@ public class TransactionHandler extends
}
public synchronized void bind(TransactionManager tm) {
- for (TransactionnalMethod method : m_methods) {
+ for (TransactionalMethod method : m_methods) {
method.setTransactionManager(tm);
}
}
public synchronized void unbind(TransactionManager tm) {
- for (TransactionnalMethod method : m_methods) {
+ for (TransactionalMethod method : m_methods) {
method.setTransactionManager(null);
}
}