You are viewing a plain text version of this content. The canonical link for it is here.
Posted to photark-commits@incubator.apache.org by lr...@apache.org on 2011/02/12 19:10:40 UTC
svn commit: r1070131 - in /incubator/photark/trunk:
photark-filesystem/src/main/java/org/apache/photark/filesystem/services/
photark-flickr/src/test/java/org/apache/photark/album/flickr/
photark-jcr/src/main/java/org/apache/photark/jcr/album/subscripti...
Author: lresende
Date: Sat Feb 12 19:10:39 2011
New Revision: 1070131
URL: http://svn.apache.org/viewvc?rev=1070131&view=rev
Log:
PHOTARK-62 - Adding missing Apache License headers, removing author specific info and minor cleanup around unused package imports
Modified:
incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemAlbumImpl.java
incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemGalleryImpl.java
incubator/photark/trunk/photark-flickr/src/test/java/org/apache/photark/album/flickr/FlickrSubscriptionTestCase.java
incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/album/subscription/AlbumSubscriptionManager.java
incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRAlbumAggregator.java
incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageUploadServiceImpl.java
incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRRemoteGalleryImpl.java
incubator/photark/trunk/photark-picasa/src/main/java/org/apache/photark/album/picasa/PicasaPhotoStream.java
incubator/photark/trunk/photark-ui/src/main/webapp/js/constants.js
incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteAlbumSubscription.java
incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteGallery.java
Modified: incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemAlbumImpl.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemAlbumImpl.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemAlbumImpl.java (original)
+++ incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemAlbumImpl.java Sat Feb 12 19:10:39 2011
@@ -19,15 +19,6 @@
package org.apache.photark.filesystem.services;
-import java.io.File;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.photark.Image;
-import org.apache.photark.services.album.Album;
-import org.apache.photark.services.album.ImageFilter;
-import org.oasisopen.sca.annotation.Init;
-import org.oasisopen.sca.annotation.Property;
public class FileSystemAlbumImpl implements org.apache.photark.services.album.Album {
private String name;
Modified: incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemGalleryImpl.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemGalleryImpl.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemGalleryImpl.java (original)
+++ incubator/photark/trunk/photark-filesystem/src/main/java/org/apache/photark/filesystem/services/FileSystemGalleryImpl.java Sat Feb 12 19:10:39 2011
@@ -19,14 +19,9 @@
package org.apache.photark.filesystem.services;
-import java.io.File;
-import java.net.URL;
-import java.util.logging.Logger;
-
import org.apache.photark.services.album.Album;
import org.apache.photark.services.gallery.BaseGalleryImpl;
import org.apache.photark.services.gallery.Gallery;
-import org.oasisopen.sca.annotation.Init;
public class FileSystemGalleryImpl extends BaseGalleryImpl implements Gallery {
private static final java.util.logging.Logger logger =
@@ -84,7 +79,7 @@ public class FileSystemGalleryImpl exten
}
public boolean hasAlbum(String albumName) {
- return false;
+ return false;
}
public void deleteAlbum(String albumName) {
@@ -92,6 +87,6 @@ public class FileSystemGalleryImpl exten
}
public Album[] getAlbumsToSetPermission(String securityToken) {
- return new Album[0];
+ return new Album[0];
}
}
\ No newline at end of file
Modified: incubator/photark/trunk/photark-flickr/src/test/java/org/apache/photark/album/flickr/FlickrSubscriptionTestCase.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-flickr/src/test/java/org/apache/photark/album/flickr/FlickrSubscriptionTestCase.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-flickr/src/test/java/org/apache/photark/album/flickr/FlickrSubscriptionTestCase.java (original)
+++ incubator/photark/trunk/photark-flickr/src/test/java/org/apache/photark/album/flickr/FlickrSubscriptionTestCase.java Sat Feb 12 19:10:39 2011
@@ -23,7 +23,7 @@ import org.apache.photark.Image;
import org.apache.tuscany.sca.data.collection.Entry;
import org.junit.BeforeClass;
import org.junit.Test;
- // <user password="aaa" roles="photark-admin" username="aaa"/>
+
public class FlickrSubscriptionTestCase {
private static final String SUBSCRIPTION_URL = "http://api.flickr.com/services/feeds/photos_public.gne?id=24662369@N07&lang=en-us&format=atom";
private static FlickrPhotoStream photoStream;
Modified: incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/album/subscription/AlbumSubscriptionManager.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/album/subscription/AlbumSubscriptionManager.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/album/subscription/AlbumSubscriptionManager.java (original)
+++ incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/album/subscription/AlbumSubscriptionManager.java Sat Feb 12 19:10:39 2011
@@ -1,30 +1,37 @@
+/*
+ * 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.photark.jcr.album.subscription;
+import java.util.logging.Logger;
+
import org.apache.photark.Image;
import org.apache.photark.album.flickr.FlickrPhotoStream;
import org.apache.photark.album.picasa.PicasaPhotoStream;
import org.apache.photark.jcr.JCRRepositoryManager;
import org.apache.photark.jcr.services.JCRAlbumImpl;
-import org.apache.photark.jcr.services.JCRGalleryImpl;
import org.apache.photark.services.gallery.RemoteAlbumSubscription;
import org.apache.photark.services.gallery.RemoteGallery;
import org.apache.tuscany.sca.data.collection.Entry;
import org.oasisopen.sca.annotation.Reference;
import org.oasisopen.sca.annotation.Remotable;
import org.oasisopen.sca.annotation.Scope;
-import org.oasisopen.sca.annotation.Service;
-import org.apache.tuscany.sca.data.collection.Entry;
-
-import java.util.logging.Logger;
-
-/**
- * Created by IntelliJ IDEA.
- * User: subash
- * Date: Jan 31, 2011
- * Time: 2:11:15 PM
- * To change this template use File | Settings | File Templates.
- */
@Remotable
@Scope("COMPOSITE")
public class AlbumSubscriptionManager implements RemoteAlbumSubscription {
Modified: incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRAlbumAggregator.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRAlbumAggregator.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRAlbumAggregator.java (original)
+++ incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRAlbumAggregator.java Sat Feb 12 19:10:39 2011
@@ -1,18 +1,38 @@
+/*
+ * 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.photark.jcr.services;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
import java.util.logging.Logger;
-import org.apache.photark.jcr.JCRRepositoryManager;
-import org.apache.photark.Image;
-import org.apache.photark.services.album.Album;
-import org.apache.photark.services.album.AlbumAgregator;
-
import javax.jcr.Node;
import javax.jcr.NodeIterator;
import javax.jcr.RepositoryException;
import javax.jcr.Session;
+import org.apache.photark.jcr.JCRRepositoryManager;
+import org.apache.photark.services.album.Album;
+import org.apache.photark.services.album.AlbumAgregator;
+
public class JCRAlbumAggregator extends AlbumAgregator {
private JCRRepositoryManager repositoryManager;
Modified: incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageUploadServiceImpl.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageUploadServiceImpl.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageUploadServiceImpl.java (original)
+++ incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageUploadServiceImpl.java Sat Feb 12 19:10:39 2011
@@ -19,11 +19,20 @@
package org.apache.photark.jcr.services;
+import static org.apache.photark.security.utils.Constants.ACCESS_LIST;
+import static org.apache.photark.security.utils.Constants.ALBUM_ADD_IMAGES_PERMISSION;
+import static org.apache.photark.security.utils.Constants.ALBUM_CREATE_PERMISSION;
+import static org.apache.photark.security.utils.Constants.ALBUM_DELETE_IMAGES_PERMISSION;
+import static org.apache.photark.security.utils.Constants.ALBUM_EDIT_ALBUM_DESCRIPTION_PERMISSION;
+
import java.io.BufferedInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.Iterator;
+import java.util.List;
import java.util.logging.Level;
import java.util.logging.Logger;
@@ -44,14 +53,12 @@ import org.apache.photark.jcr.JCRReposit
import org.apache.photark.jcr.util.ArchiveFileExtractor;
import org.apache.photark.security.authorization.AccessList;
import org.apache.photark.security.authorization.services.AccessManager;
-import org.apache.photark.security.authorization.services.SecurityServiceImpl;
import org.apache.photark.services.album.Album;
import org.apache.photark.services.gallery.Gallery;
import org.oasisopen.sca.annotation.Init;
import org.oasisopen.sca.annotation.Reference;
import org.oasisopen.sca.annotation.Scope;
import org.oasisopen.sca.annotation.Service;
-import static org.apache.photark.security.utils.Constants.*;
/**
* Servlet responsible for receiving image uploads
Modified: incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRRemoteGalleryImpl.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRRemoteGalleryImpl.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRRemoteGalleryImpl.java (original)
+++ incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRRemoteGalleryImpl.java Sat Feb 12 19:10:39 2011
@@ -1,37 +1,47 @@
+/*
+ * 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.photark.jcr.services;
-import org.apache.photark.services.gallery.GalleryListener;
-import org.apache.photark.services.gallery.RemoteGallery;
+import static org.apache.photark.security.utils.Constants.ALBUM_VIEW_IMAGES_PERMISSION;
+import static org.apache.photark.security.utils.Constants.GUEST;
-import java.io.File;
-import java.net.URL;
import java.util.ArrayList;
-import java.util.GregorianCalendar;
-import java.util.Iterator;
import java.util.List;
import java.util.logging.Logger;
-import javax.jcr.*;
+import javax.jcr.Node;
+import javax.jcr.PathNotFoundException;
+import javax.jcr.RepositoryException;
+import javax.jcr.Session;
import org.apache.photark.Image;
import org.apache.photark.jcr.JCRRepositoryManager;
import org.apache.photark.security.authorization.services.AccessManager;
import org.apache.photark.services.album.Album;
-import org.apache.photark.services.gallery.BaseGalleryImpl;
-import org.apache.photark.services.gallery.Gallery;
-import org.oasisopen.sca.annotation.*;
+import org.apache.photark.services.gallery.GalleryListener;
+import org.apache.photark.services.gallery.RemoteGallery;
+import org.oasisopen.sca.annotation.AllowsPassByReference;
+import org.oasisopen.sca.annotation.Init;
import org.oasisopen.sca.annotation.Property;
+import org.oasisopen.sca.annotation.Reference;
+import org.oasisopen.sca.annotation.Scope;
-import static org.apache.photark.security.utils.Constants.*;
-
-
-/**
- * Created by IntelliJ IDEA.
- * User: subash
- * Date: Jan 27, 2011
- * Time: 4:43:03 PM
- * To change this template use File | Settings | File Templates.
- */
@Scope("COMPOSITE")
public class JCRRemoteGalleryImpl implements RemoteGallery {
Modified: incubator/photark/trunk/photark-picasa/src/main/java/org/apache/photark/album/picasa/PicasaPhotoStream.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-picasa/src/main/java/org/apache/photark/album/picasa/PicasaPhotoStream.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-picasa/src/main/java/org/apache/photark/album/picasa/PicasaPhotoStream.java (original)
+++ incubator/photark/trunk/photark-picasa/src/main/java/org/apache/photark/album/picasa/PicasaPhotoStream.java Sat Feb 12 19:10:39 2011
@@ -23,7 +23,6 @@ import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.ArrayList;
-import java.util.Iterator;
import java.util.List;
import java.util.logging.Level;
import java.util.logging.Logger;
@@ -34,7 +33,6 @@ import org.apache.tuscany.sca.data.colle
import org.apache.tuscany.sca.data.collection.NotFoundException;
import com.google.gdata.client.photos.PicasawebService;
-import com.google.gdata.data.Feed;
import com.google.gdata.data.photos.AlbumFeed;
import com.google.gdata.data.photos.PhotoEntry;
import com.google.gdata.util.AuthenticationException;
Modified: incubator/photark/trunk/photark-ui/src/main/webapp/js/constants.js
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark-ui/src/main/webapp/js/constants.js?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark-ui/src/main/webapp/js/constants.js (original)
+++ incubator/photark/trunk/photark-ui/src/main/webapp/js/constants.js Sat Feb 12 19:10:39 2011
@@ -28,9 +28,7 @@ if (! photark.constants) {
photark.constants.contextRoot = "/photark/";
photark.constants.adminContextRoot = "/photark/admin/";
-//photark.constants.FlickerAlbumSubscription = photark.constants.contextRoot + "FlickerAlbumSubscription?smd";
photark.constants.RemoteAlbumSubscription = photark.constants.contextRoot + "RemoteAlbumSubscriptionManager?smd";
-//photark.constants.PicasaAlbumSubscription = photark.constants.contextRoot + "PicasaAlbumSubscription?smd";
photark.constants.GalleryServiceEndpoint = photark.constants.contextRoot + "GalleryService?smd";
photark.constants.RemoteGalleryServiceEndpoint = photark.constants.contextRoot + "JCRRemoteGallery?smd";
photark.constants.SearchServiceEndpoint = photark.constants.contextRoot + "SearchService?smd";
Modified: incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteAlbumSubscription.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteAlbumSubscription.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteAlbumSubscription.java (original)
+++ incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteAlbumSubscription.java Sat Feb 12 19:10:39 2011
@@ -1,25 +1,27 @@
+/*
+ * 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.photark.services.gallery;
-/**
- * Created by IntelliJ IDEA.
- * User: subash
- * Date: Jan 27, 2011
- * Time: 9:27:59 AM
- * To change this template use File | Settings | File Templates.
- */
import org.apache.photark.Image;
import org.apache.tuscany.sca.data.collection.Entry;
import org.oasisopen.sca.annotation.Remotable;
-import java.util.Set;
-
-/**
- * Created by IntelliJ IDEA.
- * User: siddhi
- * Date: Oct 6, 2010
- * Time: 3:26:24 PM
- * To change this template use File | Settings | File Templates.
- */
@Remotable
public interface RemoteAlbumSubscription {
Modified: incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteGallery.java
URL: http://svn.apache.org/viewvc/incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteGallery.java?rev=1070131&r1=1070130&r2=1070131&view=diff
==============================================================================
--- incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteGallery.java (original)
+++ incubator/photark/trunk/photark/src/main/java/org/apache/photark/services/gallery/RemoteGallery.java Sat Feb 12 19:10:39 2011
@@ -1,16 +1,27 @@
+/*
+ * 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.photark.services.gallery;
import org.apache.photark.Image;
import org.apache.photark.services.album.Album;
import org.oasisopen.sca.annotation.Remotable;
-/**
- * Created by IntelliJ IDEA.
- * User: subash
- * Date: Jan 27, 2011
- * Time: 4:43:26 PM
- * To change this template use File | Settings | File Templates.
- */
@Remotable
public interface RemoteGallery {