ahmedcss / facebook-java-api

Automatically exported from code.google.com/p/facebook-java-api
0 stars 0 forks source link

2.x - Make the API type safe #97

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Currently the API is not completely type safe. An effort could be made
to create the necessary changes to comply with type safety.

Example Patch (also attached to the bug):

Index: src/main/java/com/google/code/facebookapi/ExtensibleClient.java
===================================================================
--- src/main/java/com/google/code/facebookapi/ExtensibleClient.java
(revision 305)
+++ src/main/java/com/google/code/facebookapi/ExtensibleClient.java
(working copy)
@@ -412,7 +412,7 @@
        }
        if ( null != images && !images.isEmpty() ) {
            int image_count = 0;
-           for ( IPair image : images ) {
+           for ( IPair<? extends Object,URL> image : images ) {
                ++image_count;
                assert null != image.getFirst() : "Image URL must be provided";
                params.add( newPair( String.format( "image_%d", image_count ),
image.getFirst().toString() ) );

What version of the product are you using? On what operating system?

Facebook Java API 2.0.1

Please provide any additional information below.

This has already been discussed in the forum.

Original issue reported on code.google.com by cesar.ar...@gmail.com on 31 Aug 2008 at 2:50

Attachments:

GoogleCodeExporter commented 8 years ago
thank you. :)

Original comment by fern...@gmail.com on 31 Aug 2008 at 4:10