I am using ArcGIS Runtime SDK for Android and it supports wmslayer but there is no sample or code for
selection feature with using wmslayer. My app shows the map getting data from my wms server.
Do you know how I can do that?
What you want is to get featureinfo from a wms layer. This done using an operation called getfeatureinfo. This operation is not always enabled: this depends on your server. You can check whether your server supports this by running a getCapabilities request. This is an obliged operation for a wms service.
http://localhost:8080/geoserver/wms? service=wms& version=1.1.1& request=GetCapabilities
Depending on the server and the request the response may have different formats, eg xml or html. Usually xml is one of them. You can then parse this xml using xsl/...
Googling getfeatureinfo will give you several examples. You just need to pass the point and whatever other info you passed before the the wms server
http://localhost:8080/geoserver/wms? &INFO_FORMAT=application/json &REQUEST=GetFeatureInfo &EXCEPTIONS=application/vnd.ogc.se_xml &SERVICE=WMS &VERSION=1.1.1 &WIDTH=970&HEIGHT=485&X=486&Y=165&BBOX=-180,-90,180,90 &LAYERS=COUNTRYPROFILES:grp_administrative_map &QUERY_LAYERS=COUNTRYPROFILES:grp_administrative_map &TYPENAME=COUNTRYPROFILES:grp_administrative_map
Note again that this is optional: you should first check whether your server supports this. Example URLS from: http://docs.geoserver.org/stable/en/user/services/wms/reference.html