org.springframework.security.oauth.examples.sparklr.mvc
Class PhotoController

java.lang.Object
  extended by org.springframework.security.oauth.examples.sparklr.mvc.PhotoController

@Controller
public class PhotoController
extends Object

Controller for managing the lists of controllers for a person.

Author:
Ryan Heaton, Dave Syer

Constructor Summary
PhotoController()
           
 
Method Summary
 org.springframework.http.ResponseEntity<String> getJsonPhotos(String callback)
           
 org.springframework.http.ResponseEntity<byte[]> getPhoto(String id)
           
 org.springframework.http.ResponseEntity<String> getXmlPhotos()
           
 void setPhotoService(PhotoService photoService)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PhotoController

public PhotoController()
Method Detail

getJsonPhotos

@RequestMapping(value="/photos",
                params="format=json")
@ResponseBody
public org.springframework.http.ResponseEntity<String> getJsonPhotos(@RequestParam(required=false)
                                                                                                            String callback)
                                                              throws Exception
Throws:
Exception

getXmlPhotos

@RequestMapping(value="/photos",
                params="format=xml")
@ResponseBody
public org.springframework.http.ResponseEntity<String> getXmlPhotos()
                                                             throws Exception
Throws:
Exception

getPhoto

@RequestMapping(value="/photos/{photoId}")
public org.springframework.http.ResponseEntity<byte[]> getPhoto(@PathVariable(value="photoId")
                                                                                    String id)
                                                         throws IOException
Throws:
IOException

setPhotoService

public void setPhotoService(PhotoService photoService)


Copyright © 2012. All Rights Reserved.