[jboss-cvs] JBossAS SVN: r92019 - projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Aug 5 15:30:43 EDT 2009


Author: alesj
Date: 2009-08-05 15:30:43 -0400 (Wed, 05 Aug 2009)
New Revision: 92019

Added:
   projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatchersResourceFilter.java
Removed:
   projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatcherResourceFilter.java
Log:
Rename.

Deleted: projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatcherResourceFilter.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatcherResourceFilter.java	2009-08-05 19:28:54 UTC (rev 92018)
+++ projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatcherResourceFilter.java	2009-08-05 19:30:43 UTC (rev 92019)
@@ -1,97 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployers.vfs.spi.structure.modified;
-
-import java.util.Set;
-
-import org.jboss.deployers.vfs.spi.deployer.PathMatcher;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.virtual.VirtualFileFilter;
-import org.jboss.util.collection.ConcurrentSet;
-
-/**
- * For virtual file filter we use delegate,
- * as we already have FileStructure that collects all FileMatchers
- * which is what we want to use to check if file is accepted.
- *
- * For structure cache filer we use PathMatchers.
- * They should be injected via MC's IoC incallback.
- *
- * Note: delegate's file matchers and this class' path matchers should be the same instance
- * otherwise there might be potential compatibility issue on VFS children and StructureCache nodes.
- * @see org.jboss.deployers.vfs.spi.deployer.AbstractResourceMatcher
- *
- * @author <a href="mailto:ales.justin at jboss.org">Ales Justin</a>
- */
-public class PathMatcherResourceFilter implements StructureCacheFilter, VirtualFileFilter
-{
-   /** The path matchers */
-   private Set<PathMatcher> pathMatchers = new ConcurrentSet<PathMatcher>();
-
-   /** The virtual file filter delegate */
-   private VirtualFileFilter delegate;
-
-   public PathMatcherResourceFilter(VirtualFileFilter delegate)
-   {
-      if (delegate == null)
-         throw new IllegalArgumentException("Null delegate");
-
-      this.delegate = delegate;
-   }
-
-   public boolean accepts(String path)
-   {
-      for (PathMatcher pm : pathMatchers)
-      {
-         if (pm.isDeployable(path))
-            return true;
-      }
-      return false;
-   }
-
-   public boolean accepts(VirtualFile file)
-   {
-      return delegate.accepts(file);
-   }
-
-   /**
-    * Add path matcher.
-    *
-    * @param pm the path matcher
-    * @return Set#add
-    */
-   public boolean addFileMatcher(PathMatcher pm)
-   {
-      return pathMatchers.add(pm);
-   }
-
-   /**
-    * Remove path matcher.
-    *
-    * @param pm the path matcher
-    * @return Set#remove
-    */
-   public boolean removeFileMatcher(PathMatcher pm)
-   {
-      return pathMatchers.remove(pm);
-   }
-}
\ No newline at end of file

Copied: projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatchersResourceFilter.java (from rev 92018, projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatcherResourceFilter.java)
===================================================================
--- projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatchersResourceFilter.java	                        (rev 0)
+++ projects/jboss-deployers/trunk/deployers-vfs-spi/src/main/java/org/jboss/deployers/vfs/spi/structure/modified/PathMatchersResourceFilter.java	2009-08-05 19:30:43 UTC (rev 92019)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.deployers.vfs.spi.structure.modified;
+
+import java.util.Set;
+
+import org.jboss.deployers.vfs.spi.deployer.PathMatcher;
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.VirtualFileFilter;
+import org.jboss.util.collection.ConcurrentSet;
+
+/**
+ * For virtual file filter we use delegate,
+ * as we already have FileStructure that collects all FileMatchers
+ * which is what we want to use to check if file is accepted.
+ *
+ * For structure cache filer we use PathMatchers.
+ * They should be injected via MC's IoC incallback.
+ *
+ * Note: delegate's file matchers and this class' path matchers should be the same instance
+ * otherwise there might be potential compatibility issue on VFS children and StructureCache nodes.
+ * @see org.jboss.deployers.vfs.spi.deployer.AbstractResourceMatcher
+ *
+ * @author <a href="mailto:ales.justin at jboss.org">Ales Justin</a>
+ */
+public class PathMatchersResourceFilter implements StructureCacheFilter, VirtualFileFilter
+{
+   /** The path matchers */
+   private Set<PathMatcher> pathMatchers = new ConcurrentSet<PathMatcher>();
+
+   /** The virtual file filter delegate */
+   private VirtualFileFilter delegate;
+
+   public PathMatchersResourceFilter(VirtualFileFilter delegate)
+   {
+      if (delegate == null)
+         throw new IllegalArgumentException("Null delegate");
+
+      this.delegate = delegate;
+   }
+
+   public boolean accepts(String path)
+   {
+      for (PathMatcher pm : pathMatchers)
+      {
+         if (pm.isDeployable(path))
+            return true;
+      }
+      return false;
+   }
+
+   public boolean accepts(VirtualFile file)
+   {
+      return delegate.accepts(file);
+   }
+
+   /**
+    * Add path matcher.
+    *
+    * @param pm the path matcher
+    * @return Set#add
+    */
+   public boolean addFileMatcher(PathMatcher pm)
+   {
+      return pathMatchers.add(pm);
+   }
+
+   /**
+    * Remove path matcher.
+    *
+    * @param pm the path matcher
+    * @return Set#remove
+    */
+   public boolean removeFileMatcher(PathMatcher pm)
+   {
+      return pathMatchers.remove(pm);
+   }
+}
\ No newline at end of file




More information about the jboss-cvs-commits mailing list