freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

geoserver開發(fā)手冊系列(編輯修改稿)

2025-07-23 11:54 本頁面
 

【文章內(nèi)容簡介】 x=3 list valuesayHello/value /list /constructorarg /bean/beans到此,hello工程內(nèi)容應(yīng)該是看上去像下面這樣了:hello/ + + src/ + main/ + java/ + + 試一試1. 安裝hello模塊。[hello]% mvn install[hello]% mvn install[INFO] Scanning for projects...[INFO] [INFO] Building Hello World Service Module[INFO] tasksegment: [install][INFO] [INFO] [resources:resources][INFO] Using default encoding to copy filtered resources.[INFO] [piler:pile][INFO] Compiling 1 source file to /home/ak/geoserver/munity/hello/target/classes[INFO] [resources:testResources][INFO] Using default encoding to copy filtered resources.[INFO] [piler:testCompile][INFO] No sources to pile[INFO] [surefire:test][INFO] No tests to run.[INFO] [jar:jar][INFO] Building jar: /home/ak/geoserver/munity/hello/target/[INFO] [jar:testjar {execution: default}][WARNING] JAR will be empty no content was marked for inclusion![INFO] Building jar: /home/ak/geoserver/munity/hello/target/[INFO] [install:install][INFO] Installing /home/ak/geoserver/munity/hello/target/ to /home/ak/.m2/repository/org/geoserver/hello/[INFO] Installing /home/ak/geoserver/munity/hello/target/ to /home/ak/.m2/repository/org/geoserver/hello/[INFO] [INFO] BUILD SUCCESSFUL[INFO] [INFO] Total time: 6 seconds[INFO] Finished at: Fri Sep 21 14:52:31 EDT 2007[INFO] Final Memory: 27M/178M[INFO] 。::host/geoserver/ows?request=sayHelloamp。service=helloamp。version=請求request 我們服務(wù)內(nèi)定義的方法服務(wù)service 版本version 另外一個可選方法是在新的插件工程上從web模塊申明一個依賴。1. 像上面一樣安裝hello模塊。2. 編輯web/,添加如下依賴:dependency groupId/groupId artifactIdhello/artifactId version/version/dependency3. 安裝、運行web模塊[web] mvn install jetty:run4. 訪問:://localhost:8080/geoserver/ows?request=sayHelloamp。service=helloamp。version=可選方法2:由GeoServer源中運行作為嘗試插件開發(fā)的一種可選方法:1. 安裝hello模塊。2. 更改路徑到web模塊3. 安裝web模塊。4. 拷貝hello module/target/web module/target/geoserver/WEBINF/lib目錄 :[/dev/geoserver/web]% cp ~/hello/target/ target/geoserver/WEBINF/lib5. 使用Jetty運行打包的war。[/dev/geoserver/web]% mvn jetty6:runexploded6. 訪問:://localhost:8080/geoserver/ows?request=sayHelloamp。service=helloamp。version=REST服務(wù)本節(jié)是GeoServer中運行RESTful服務(wù)的的預(yù)覽。簡介GeoServer使用著名的Restlet庫提供系統(tǒng)所有REST相關(guān)功能。Restlet是由Java編寫的輕量級rest框架,它能很好的集成基于已有的servlet的應(yīng)用程序Rest派發(fā)GeoServer里面,所有路徑/rest下面的請求都被認為是一個restful請求。這每一個請求都交由一個rest派發(fā)器來處理。派發(fā)器的工作職責(zé)是請每個請求導(dǎo)向到相關(guān)的處理終端上。該終端就是restlet。Restlet由spring環(huán)境加載,因此它們是可插拔的。RestletsRestlet是處理派發(fā)器轉(zhuǎn)發(fā)來的調(diào)用。我們可以擴展該類以實現(xiàn)一個服務(wù)端點(服務(wù)點)。同樣,我們也可以為了某個特殊目的擴展出一個子類。下節(jié)描述的就是一個名為finder的子類。Finders和資源Restful服務(wù)通常是實現(xiàn)了某一個資源。Finder對象是一個特殊的restlet,它的職責(zé)是為特定的請求找到正確的資源。該資源就作為一個最終的終點,并處理請求。表達Representations182。Repreentation,通常是指特殊狀態(tài)的狀態(tài)或者資源編碼的格式。例如,當(dāng)某個特殊資源請求進來時,該資源的表達就返回給了客戶端。RESTful服務(wù)實現(xiàn)本節(jié)描述GeoServer如何實現(xiàn)一個restful服務(wù),將以“hello world”為示例。該服務(wù)非常簡單,將會向一個GET請求返回一個“Hello World”的文本。預(yù)置條件在開始之前,GeoServer必須在本地系統(tǒng)上構(gòu)建成功。具體細節(jié)見源代碼和快速入門兩節(jié)。創(chuàng)建新模塊1. 在本地系統(tǒng)某處創(chuàng)建一個名為hello_rest的新模塊。2. :project xmlns= xmlns:xsi= xsi:schemaLocation=:// modelVersion/modelVersion groupId/groupId artifactIdhello_rest/artifactId packagingjar/packaging version/version namehello_rest/name dependencies dependency groupId/groupId artifactIdrest/artifactId version/version /dependency dependency groupId/groupId artifactIdmain/artifactId version/version classifiertests/classifier scopetest/scope /dependency dependency groupIdjunit/groupId artifactIdjunit/artifactId version/version scopetest/scope /dependency dependency groupId/groupId artifactIdmockrunner/artifactId version/version scopetest/scope /dependency /dependencies build plugins plugin artifactIdmavenpilerplugin/artifactId configuration source/source target/target /configuration /plugin /plugins /build/project1. 在新模塊根部創(chuàng)建src/main/java目錄[hello_rest]% mkdir p src/main/java創(chuàng)建資源類1. 當(dāng)創(chuàng)建新的資源時。,它由AbstractResource擴展。package 。import 。import 。import 。import 。import 。public class HelloResource extends AbstractResource { @Override protected ListDataFormat createSupportedFormats(Request request, Response response) { return null。 }}2.第一個要實現(xiàn)的方法是createSupportedFormats()。該方法的目的是創(chuàng)建一個由擴展到特殊格式的映射。那么好,現(xiàn)在我們的目標(biāo)就是給客戶端的“.txt”擴展請求返回“Hello World”的文本。import 。import 。...@Overrideprotected ListDataFormat createSupportedFormats(Request request, Response response) { ListDataFormat formats = new ArrayList()。 (new StringFormat( ))。 return formats。}2. 接下來需要覆蓋handleGet()方法。該方法在資源的GET請求拿到時調(diào)用。@Overridepublic void handleGet() { //get the appropriate format DataFormat format = getFormatGet()。 //transform the string Hello World to the appropriate response getResponse().setEntity((Hello World))。}上面代碼使用getFormatGet()方法,該方法的目的是確定客戶端請求的擴展,并為它找到對應(yīng)的格式。在本例中,當(dāng)客戶端請求“.txt”擴展時,就可看到前面步驟中的StringFormat創(chuàng)建了。創(chuàng)建應(yīng)用程序環(huán)境1. 下面一步是創(chuàng)建應(yīng)用程序環(huán)境,用以告知GeoServer上節(jié)中所創(chuàng)建的資源。在hello_rest模塊根部創(chuàng)建src/main/resources目錄。[hello_rest]% mkdir src/main/resources2. 在hello_rest模塊根部創(chuàng)建src/main/。!DOCTYPE beans PUBLIC //SPRING//DTD BEAN//EN beans bean id=hello class=/ bean id=helloMapping class=
點擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖片鄂ICP備17016276號-1