Last modified: Mon, 04/03/2017 - 17:28
Given a data set, variable and a view find the operations that can be applied (and the options for each operation).
The URL forthis action is:
http://server.gov:8080/las/getOperations.do?dsid=datasetID&varid=variabl...
This response does not include the options. You have to call getOptions using the IDREF in the optionsdef element to get the options.
For example, the response for an LAS that contains the coads_climatology_cdf data set and the SST variable with an xy view looks like this:
{"operations": {"operation": [ { "service": "ferret", "optiondef": {"IDREF": "Options_gen_script"}, "region": {"intervals": [ {"name": "x"}, {"name": "y"}, {"name": "z"}, {"name": "t"}, {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"}, {"name": "xyz"}, {"name": "xyt"}, {"name": "xzt"}, {"name": "yzt"}, {"name": "xyzt"} ]}, "output_template": "scripts", "grid_types": {"grid_type": [ {"name": "regular"}, {"name": "scattered"} ]}, "service_action": "Convert_to_Index", "name": "Data Access Scripts for Desktop Apps", "response": { "result": { "type": "index", "file_suffix": ".xml", "ID": "index" }, "ID": "ConvertResp" }, "ID": "Gen_Scripts" }, { "service": "ferret", "optiondef": {"IDREF": "Options_2D"}, "region": {"intervals": [ {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"} ]}, "output_template": "output", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Overlay_Plot_2D", "name": "2D Overlay Plot", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "ID": "map_scale" }, { "type": "debug", "ID": "debug" }, { "type": "cancel", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Overlay_Plot_2D" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Compare"}, "region": {"intervals": [ {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"} ]}, "output_template": "output", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Compare_Plot", "name": "2D Difference Plot", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Compare_Plot" }, { "service": "ferret", "optiondef": {"IDREF": "Options_2D_image_contour_xy"}, "region": {"intervals": {"name": "xy"}}, "output_template": "output", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Plot_2D_XY", "name": "2D Plot in XY", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Plot_2D_XY" }, { "service": "ferret", "region": {"intervals": {"name": "xy"}}, "output_template": "output", "grid_types": {"grid_type": {"name": "regular"}}, "optionsdef": {"IDREF": "Options_2D_image_contour_xy"}, "service_action": "xy_map", "name": "xy map", "response": { "result": [ { "streamable": "true", "type": "image", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "ID": "ref_map" }, { "type": "map_scale", "ID": "map_scale" }, { "type": "debug", "ID": "debug" }, { "type": "cancel", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "xy_map" }, { "service": "ferret", "region": {"intervals": {"name": "xy"}}, "output_template": "output_GE_overlay", "grid_types": {"grid_type": {"name": "regular"}}, "optionsdef": {"IDREF": "Options_2D_image_contour_xy"}, "service_action": "Plot_2D_GE", "name": "Googel Earth Overlay", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Plot_GE_Overlay" }, { "region": {"intervals": {"name": "xy"}}, "output_template": "output_response", "grid_types": {"grid_type": {"name": "regular"}}, "name": "Plot to Google Earth", "operation": [ { "service": "ferret", "service_action": "Plot_2D_GE", "name": "Plot_2D_GE", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "colorbar" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Plot_for_GE" }, { "service": "kml", "chained": "true", "args": {"arg": [ { "chained": "true", "type": "image", "result": "plot_image", "operation": "Plot_for_GE" }, { "chained": "true", "type": "image", "result": "colorbar", "operation": "Plot_for_GE" }, { "chained": "true", "type": "map_scale", "result": "map_scale", "operation": "Plot_for_GE" } ]}, "service_action": "kml", "name": "Make KML File", "response": { "index": "1", "type": "HTML", "result": { "streamable": "true", "type": "kml", "file_suffix": ".kml", "mime_type": "application/vnd.google-earth.kml+xml", "ID": "kml" }, "ID": "PlotResp" }, "ID": "kml" } ], "ID": "Plot_GE_kml" }, { "service": "ferret", "region": {"intervals": {"name": "xy"}}, "output_template": "output_GE_overlay", "grid_types": {"grid_type": {"name": "regular"}}, "optionsdef": {"IDREF": "Options_Vector"}, "service_action": "Plot_vector_GE", "name": "Googel Earth Overlay", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Vector_GE_Overlay" }, { "region": {"intervals": {"name": "xy"}}, "output_template": "output_response", "grid_types": {"grid_type": {"name": "regular"}}, "name": "Google Earth kml", "operation": [ { "service": "ferret", "service_action": "Plot_vector_GE", "name": "Plot_vector_GE", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Vector_for_GE" }, { "service": "kml", "chained": "true", "args": {"arg": [ { "chained": "true", "type": "image", "result": "plot_image", "operation": "Vector_for_GE" }, { "chained": "true", "type": "map_scale", "result": "map_scale", "operation": "Vector_for_GE" } ]}, "service_action": "kml_vector", "name": "Make KML File", "response": { "index": "1", "type": "HTML", "result": { "streamable": "true", "type": "kml", "file_suffix": ".kml", "mime_type": "application/vnd.google-earth.kml+xml", "ID": "kml" }, "ID": "PlotResp" }, "ID": "kml" } ], "ID": "Vector_GE_kml" }, { "service": "ferret", "region": {"intervals": [ {"name": "x"}, {"name": "y"}, {"name": "z"}, {"name": "t"}, {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"}, {"name": "xyz"}, {"name": "xyt"}, {"name": "xzt"}, {"name": "yzt"}, {"name": "xyzt"} ]}, "output_template": "output_response", "grid_types": {"grid_type": {"name": "regular"}}, "optionsdef": {"IDREF": "Options_Data"}, "service_action": "Data_Extract_Grid", "name": "Grid Locations", "response": { "result": [ { "streamable": "true", "type": "text", "file_suffix": ".txt", "mime_type": "text/plain", "ID": "ferret_listing" }, { "type": "debug", "ID": "debug" } ], "ID": "Data_Extract_Grid_Response" }, "ID": "Data_Extract_Grid" }, { "service": "ferret", "region": {"intervals": {"name": "xy"}}, "output_template": "output_wms", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Plot_2D_WMS", "name": "2D Plot for WMS", "response": { "result": { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, "ID": "PlotResp" }, "ID": "Plot_2D_WMS" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Vector"}, "region": {"intervals": [ {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"} ]}, "output_template": "output", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Plot_vector", "name": "Vector Plot", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Plot_vector" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Data"}, "region": {"intervals": [ {"name": "x"}, {"name": "y"}, {"name": "z"}, {"name": "t"}, {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"}, {"name": "xyz"}, {"name": "xyt"}, {"name": "xzt"}, {"name": "yzt"}, {"name": "xyzt"} ]}, "output_template": "table", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Data_Extract", "name": "Table of Value", "response": { "result": [ { "streamable": "true", "type": "text", "mime_type": "text/plain", "ID": "ferret_listing" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" } ], "ID": "Data_Extract_Response" }, "ID": "Data_Extract" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Data"}, "region": {"intervals": [ {"name": "x"}, {"name": "y"}, {"name": "z"}, {"name": "t"}, {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"}, {"name": "xyz"}, {"name": "xyt"}, {"name": "xzt"}, {"name": "yzt"}, {"name": "xyzt"} ]}, "output_template": "netcdf", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Data_Extract_netCDF", "name": "Extract a sub-set into a netCDF file", "response": { "result": [ { "type": "netcdf", "file_suffix": ".nc", "ID": "ferret_listing" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" } ], "ID": "Data_Extract_netCDF_Response" }, "ID": "Data_Extract_netCDF" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Data_file"}, "region": {"intervals": [ {"name": "x"}, {"name": "y"}, {"name": "z"}, {"name": "t"}, {"name": "xy"}, {"name": "xz"}, {"name": "xt"}, {"name": "yz"}, {"name": "yt"}, {"name": "zt"}, {"name": "xyz"}, {"name": "xyt"}, {"name": "xzt"}, {"name": "yzt"}, {"name": "xyzt"} ]}, "output_template": "ascii", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Data_Extract_File", "name": "Extract a sub-set into a formatted ASCII file", "response": { "result": [ { "streamable": "true", "type": "ascii", "file_suffix": ".txt", "mime_type": "text/plain", "ID": "ferret_listing" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" } ], "ID": "Data_Extract_File_Response" }, "ID": "Data_Extract_File" }, { "service": "ferret", "optiondef": {"IDREF": "Options_Data"}, "region": {"intervals": {"name": "xy"}}, "output_template": "arcview", "grid_types": {"grid_type": {"name": "regular"}}, "service_action": "Data_Extract_ArcView", "name": "ArcView ASCII Output File", "response": { "result": [ { "type": "arc", "file_suffix": ".arc", "ID": "ferret_listing" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" } ], "ID": "Data_Extract_File_Response" }, "ID": "Data_Extract_ArcView" }, { "region": {"intervals": {"name": "xy"}}, "output_template": "output_GE", "grid_types": {"grid_type": {"name": "regular"}}, "name": "Plot to Google Earth", "operation": [ { "service": "ferret", "service_action": "Plot_2D_GE", "name": "Plot_2D_GE", "response": { "result": [ { "streamable": "true", "type": "image", "file_suffix": ".gif", "mime_type": "image/png", "ID": "plot_image" }, { "streamable": "true", "type": "ps", "file_suffix": ".ps", "mime_type": "application/postscript", "ID": "plot_postscript" }, { "type": "image", "file_suffix": ".gif", "ID": "ref_map" }, { "type": "map_scale", "file_suffix": ".xml", "ID": "map_scale" }, { "type": "debug", "file_suffix": ".txt", "ID": "debug" }, { "type": "cancel", "file_suffix": ".txt", "ID": "cancel" } ], "ID": "PlotResp" }, "ID": "Plot_for_GE" }, { "service": "kml", "chained": "true", "args": {"arg": [ { "chained": "true", "type": "image", "result": "plot_image", "file_suffix": ".gif", "operation": "Plot_for_GE" }, { "chained": "true", "type": "map_scale", "result": "map_scale", "file_suffix": ".xml", "operation": "Plot_for_GE" } ]}, "service_action": "kml", "name": "Make KML File", "response": { "index": "1", "type": "HTML", "result": { "streamable": "true", "type": "kml", "file_suffix": ".kml", "mime_type": "application/vnd.google-earth.kml+xml", "ID": "kml" }, "ID": "PlotResp" }, "ID": "kml" } ], "ID": "Google_Earth" } ]}}