com.poscoict.glueframework.web.control.restful
Class RestfulController
java.lang.Object
com.poscoict.glueframework.web.control.restful.RestfulController
@Controller
public class RestfulController
- extends Object
RESTful¹æ½ÄÀÇ À¥¼ºñ½º¸¦ Á¦°øÇÏ´Â Controller URI ÆÐÅÏÀ¸·Î´Â ¾Æ·¡ µÎ°¡Áö ¹æ½ÄÀÌ Á¦°øµÈ´Ù.
- /glue/{serviceName} : URIÀÇ serviceName°ú Service¸íÀÌ ÀÏÄ¡ÇÏ´Â Glue Servic°¡ ½ÇÇà µÈ´Ù.
- /glue/{serviceName}/data/{gluedata} : URIÀÇ serviceName°ú Service¸íÀÌ ÀÏÄ¡ÇÏ´Â Glue Servic°¡ ½ÇÇàµÇ¸ç URIÀÇ gluedata°ªÀº "gluedata"¸¦ Key·Î
GlueContext¿¡ ÀúÀåµÈ´Ù.
GET,POST,PUT,DELETE ¹æ½ÄÀÌ Áö¿øµÇ¸ç ¾î¶² ¹æ½ÄÀÇ ¿äûÀ̾ú´ÂÁö´Â "action"À» Key·Î GlueContext¿¡ ¼Ò¹®ÀÚ·Î ÀúÀåµÈ´Ù. ÇØ´ç ¿äûÀÌ Key·Îµµ µî·ÏµÇ¹Ç·Î Default Router·Î ºÐ±âµµ °¡´ÉÇÏ´Ù. ajax¹æ½ÄÀ̳ª
RestTemplateÀ» »ç¿ëÇÏ¿© ¼ºñ½º¸¦ È£Ãâ ÇÒ ¼öÀÖÀ¸¸é JSON Çü½ÄÀÇ µ¥ÀÌÅÍ°¡ ReturnµÈ´Ù.
Method Summary |
ModelAndView |
doGlueServiceDelete(String serviceName)
|
ModelAndView |
doGlueServiceDeletetByData(String serviceName,
String gluedata)
|
ModelAndView |
doGlueServiceGet(String serviceName)
|
ModelAndView |
doGlueServiceGetByData(String serviceName,
String gluedata)
|
ModelAndView |
doGlueServicePost(String serviceName,
Map<String,Object> params)
|
ModelAndView |
doGlueServicePostByData(String serviceName,
String gluedata,
Map<String,Object> params)
|
ModelAndView |
doGlueServicePut(String serviceName,
MultiValueMap<String,String> params)
|
ModelAndView |
doGlueServicePutByData(String serviceName,
String gluedata,
MultiValueMap<String,String> params)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RestfulController
public RestfulController()
doGlueServiceGet
@RequestMapping(value="/glue/{serviceName}",
method=GET)
public ModelAndView doGlueServiceGet(@PathVariable
String serviceName)
- Parameters:
serviceName
-
- Returns:
doGlueServiceGetByData
@RequestMapping(value="/glue/{serviceName}/data/{gluedata}",
method=GET)
public ModelAndView doGlueServiceGetByData(@PathVariable
String serviceName,
@PathVariable
String gluedata)
- Parameters:
serviceName
- gluedata
-
- Returns:
doGlueServiceDelete
@RequestMapping(value="/glue/{serviceName}",
method=DELETE)
public ModelAndView doGlueServiceDelete(@PathVariable
String serviceName)
- Parameters:
serviceName
-
- Returns:
doGlueServiceDeletetByData
@RequestMapping(value="/glue/{serviceName}/data/{gluedata}",
method=DELETE)
public ModelAndView doGlueServiceDeletetByData(@PathVariable
String serviceName,
@PathVariable
String gluedata)
- Parameters:
serviceName
- gluedata
-
- Returns:
doGlueServicePost
@RequestMapping(value="/glue/{serviceName}",
method=POST)
public ModelAndView doGlueServicePost(@PathVariable
String serviceName,
@RequestParam
Map<String,Object> params)
- Parameters:
serviceName
- params
-
- Returns:
doGlueServicePostByData
@RequestMapping(value="/glue/{serviceName}/data/{gluedata}",
method=POST)
public ModelAndView doGlueServicePostByData(@PathVariable
String serviceName,
@PathVariable
String gluedata,
@RequestParam
Map<String,Object> params)
- Parameters:
serviceName
- gluedata
- params
-
- Returns:
doGlueServicePut
@RequestMapping(value="/glue/{serviceName}",
method=PUT)
public ModelAndView doGlueServicePut(@PathVariable
String serviceName,
@RequestBody
MultiValueMap<String,String> params)
- Parameters:
serviceName
- params
-
- Returns:
doGlueServicePutByData
@RequestMapping(value="/glue/{serviceName}/data/{gluedata}",
method=PUT)
public ModelAndView doGlueServicePutByData(@PathVariable
String serviceName,
@PathVariable
String gluedata,
@RequestBody
MultiValueMap<String,String> params)
- Parameters:
serviceName
- gluedata
- params
-
- Returns:
Copyright © 2013–2017 POSCO ICT. All rights reserved.