Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 71818 invoked from network); 6 Jan 2007 15:42:04 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 6 Jan 2007 15:42:04 -0000 Received: (qmail 5322 invoked by uid 500); 6 Jan 2007 15:42:08 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 5241 invoked by uid 500); 6 Jan 2007 15:42:08 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 5230 invoked by uid 500); 6 Jan 2007 15:42:08 -0000 Received: (qmail 5227 invoked by uid 99); 6 Jan 2007 15:42:08 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 06 Jan 2007 07:42:08 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 06 Jan 2007 07:42:00 -0800 Received: by eris.apache.org (Postfix, from userid 65534) id 9AB051A9820; Sat, 6 Jan 2007 07:41:02 -0800 (PST) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r493489 - in /jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file: DirectTransactionIdToPathMapper.java FileResourceManager.java NoOpTransactionIdToPathMapper.java Date: Sat, 06 Jan 2007 15:41:02 -0000 To: commons-cvs@jakarta.apache.org From: joerg@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20070106154102.9AB051A9820@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: joerg Date: Sat Jan 6 07:41:01 2007 New Revision: 493489 URL: http://svn.apache.org/viewvc?view=rev&rev=493489 Log: before it gets released: rename DirectTITPMapper to NoOpTITPMapper and really do nothing (using toString() in the one direction and doing nothing in the other one was somewhat inconsistent) Added: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java (with props) Removed: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/DirectTransactionIdToPathMapper.java Modified: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java Modified: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java URL: http://svn.apache.org/viewvc/jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java?view=diff&rev=493489&r1=493488&r2=493489 ============================================================================== --- jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java (original) +++ jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java Sat Jan 6 07:41:01 2007 @@ -1,10 +1,4 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//transaction/src/java/org/apache/commons/transaction/file/FileResourceManager.java,v 1.6 2005/01/07 13:32:33 ozeigermann Exp $ - * $Revision$ - * $Date$ - * - * ==================================================================== - * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. @@ -19,9 +13,7 @@ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - * */ - package org.apache.commons.transaction.file; import java.io.BufferedReader; @@ -237,7 +229,7 @@ boolean urlEncodePath, LoggerFacade logger, boolean debug) { - this(storeDir, workDir, urlEncodePath ? new URLEncodeIdMapper() : null, new DirectTransactionIdToPathMapper(), logger, debug); + this(storeDir, workDir, urlEncodePath ? new URLEncodeIdMapper() : null, new NoOpTransactionIdToPathMapper(), logger, debug); } /** Added: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java URL: http://svn.apache.org/viewvc/jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java?view=auto&rev=493489 ============================================================================== --- jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java (added) +++ jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java Sat Jan 6 07:41:01 2007 @@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.commons.transaction.file; + +/** + * Default implementation of {@link TransactionIdToPathMapper}, which expects + * transaction ids being strings and using them as path. + * + * @version $Id$ + * @since 1.2 + */ +public class NoOpTransactionIdToPathMapper implements TransactionIdToPathMapper { + + public String getPathForId(Object txId) { + return (String)txId; + } + + public Object getIdForPath(String path) { + return path; + } + +} Propchange: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/NoOpTransactionIdToPathMapper.java ------------------------------------------------------------------------------ svn:eol-style = native --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org