diff options
author | Sam Blitzstein <sblitz@google.com> | 2013-10-16 17:08:25 -0700 |
---|---|---|
committer | Sam Blitzstein <sblitz@google.com> | 2013-10-16 17:47:50 -0700 |
commit | 25ad6f98516a7af1ca71cfa07fb503d46dc8a7f1 (patch) | |
tree | efdefb7ddeb0204bd48e1e376e602b52b189e4b5 | |
parent | d2e1718fa8e1199b03dc0d069711b24e946aa858 (diff) | |
download | bitmap-25ad6f98516a7af1ca71cfa07fb503d46dc8a7f1.tar.gz |
Add copyright notices, and clarify documentation.
Remove ineffectual interface methods from RequestKey and replace with a comment in the class's
documentation to the same meaning.
Change-Id: I4d27407d18a798b27dfe138b38a5ee3a2718e127
-rw-r--r-- | sample/AndroidManifest.xml | 2 | ||||
-rw-r--r-- | sample/res/layout/activity_main.xml | 16 | ||||
-rw-r--r-- | sample/res/values/dimens.xml | 16 | ||||
-rw-r--r-- | sample/res/values/strings.xml | 15 | ||||
-rw-r--r-- | sample/res/values/styles.xml | 16 | ||||
-rw-r--r-- | sample/src/com/example/bitmapsample/BitmapView.java | 16 | ||||
-rw-r--r-- | sample/src/com/example/bitmapsample/MainActivity.java | 17 | ||||
-rw-r--r-- | src/com/android/bitmap/RequestKey.java | 10 |
8 files changed, 99 insertions, 9 deletions
diff --git a/sample/AndroidManifest.xml b/sample/AndroidManifest.xml index 178b666..8c15a50 100644 --- a/sample/AndroidManifest.xml +++ b/sample/AndroidManifest.xml @@ -15,7 +15,7 @@ --> <manifest xmlns:android="http://schemas.android.com/apk/res/android" - package="com.example.bitmapcachesample" + package="com.example.bitmapsample" android:versionCode="1" android:versionName="1.0" > diff --git a/sample/res/layout/activity_main.xml b/sample/res/layout/activity_main.xml index 2026d9a..f182664 100644 --- a/sample/res/layout/activity_main.xml +++ b/sample/res/layout/activity_main.xml @@ -1,3 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed 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. +--> + <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" diff --git a/sample/res/values/dimens.xml b/sample/res/values/dimens.xml index 0bd0996..f009504 100644 --- a/sample/res/values/dimens.xml +++ b/sample/res/values/dimens.xml @@ -1,3 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed 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. +--> + <resources> <!-- Default screen margins, per the Android Design guidelines. --> diff --git a/sample/res/values/strings.xml b/sample/res/values/strings.xml index 1f56393..7a45f1c 100644 --- a/sample/res/values/strings.xml +++ b/sample/res/values/strings.xml @@ -1,4 +1,19 @@ <?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed 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. +--> + <resources> <string name="app_name">BitmapTest</string> diff --git a/sample/res/values/styles.xml b/sample/res/values/styles.xml index 6ce89c7..ec1a8f0 100644 --- a/sample/res/values/styles.xml +++ b/sample/res/values/styles.xml @@ -1,3 +1,19 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed 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. +--> + <resources> <!-- diff --git a/sample/src/com/example/bitmapsample/BitmapView.java b/sample/src/com/example/bitmapsample/BitmapView.java index 5ca7dcd..8b5bd69 100644 --- a/sample/src/com/example/bitmapsample/BitmapView.java +++ b/sample/src/com/example/bitmapsample/BitmapView.java @@ -1,3 +1,19 @@ +/* + * Copyright (C) 2013 The Android Open Source Project + * + * Licensed 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 com.example.bitmapsample; import android.content.Context; diff --git a/sample/src/com/example/bitmapsample/MainActivity.java b/sample/src/com/example/bitmapsample/MainActivity.java index 6b612d4..78b2ec6 100644 --- a/sample/src/com/example/bitmapsample/MainActivity.java +++ b/sample/src/com/example/bitmapsample/MainActivity.java @@ -1,3 +1,19 @@ +/* + * Copyright (C) 2013 The Android Open Source Project + * + * Licensed 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 com.example.bitmapsample; import android.app.Activity; @@ -10,7 +26,6 @@ import android.widget.ListView; import com.android.bitmap.BitmapCache; import com.android.bitmap.UnrefedBitmapCache; import com.android.bitmap.util.Trace; -import com.example.bitmapcachesample.R; public class MainActivity extends Activity { private ListView mListView; diff --git a/src/com/android/bitmap/RequestKey.java b/src/com/android/bitmap/RequestKey.java index eadb42d..108b255 100644 --- a/src/com/android/bitmap/RequestKey.java +++ b/src/com/android/bitmap/RequestKey.java @@ -29,16 +29,12 @@ import java.io.InputStream; * <p> * Objects of this type will also serve as cache keys to fetch cached data for {@link PooledCache}s, * so they must implement {@link #equals(Object)} and {@link #hashCode()}. + * <p> + * Clients of this interface must also implement {@link #equals(Object)} and {@link #hashCode()} as + * this object will be used as a cache key. */ public interface RequestKey { - - @Override - public boolean equals(Object o); - - @Override - public int hashCode(); - /** * Create an {@link AssetFileDescriptor} for a local file stored on the device. This method will * be called first; if it returns null, {@link #createInputStream()} will be called. |