Method | Description | |
---|---|---|
AddItem ( long zipCode ) : bool |
add a new item given only a zipcode (will use the default location given by the service) should the item exists, it will get updated
|
|
AddItem ( long zipCode, double lat, double lon ) : bool |
adds a new item given a zipcode and a coordinate. Should the item already exists, it will get updated and will move to the new coordinate.
|
|
Connect ( ) : void |
connects to RSS weather service
|
|
DeleteItem ( long zipCode ) : bool |
delete an item from the dataset
|
|
Disconnect ( ) : void |
disconnects from RSS weather service
|
|
Draw ( esriDrawPhase drawPhase, IDisplay Display, ITrackCancel trackCancel ) : void |
Draws the layer to the specified display for the given draw phase. the draw method is set as an abstract method and therefore must be overridden |
|
DrawDynamicLayer ( esriDynamicDrawPhase DynamicDrawPhase, IDisplay Display, IDynamicDisplay DynamicDisplay ) : void |
Draw the layer while in dynamic mode
|
|
GetCityNames ( ) : string[] |
get a list of all citynames currently in the dataset. Please note that since the unique ID is zipCode, it is possible to have a city name appearing more than once. |
|
GetWeatherItem ( long zipCode ) : IPropertySet |
This method searches for the record of the given zipcode and retunes the information as a PropertySet.
|
|
GetWeatherItem ( string cityName ) : IPropertySet |
get a weather item given a city name. a city might have more than one zipCode and therefore this method will return the first zipcOde found for the specified city name. |
|
Identify ( IGeometry pGeom ) : IArray |
Identifying all the weather items falling within the given envelope
|
|
RSSWeatherLayerClass ( ) : System |
The class has only default CTor.
|
|
Refresh ( ) : void |
Run the update thread calling this method to frequently might end up in blockage of RSS service. The service will interpret the excessive calls as an offence and thus would block the service for a while. |
|
Select ( long zipCode, bool newSelection ) : void |
select a weather item by its zipCode
|
|
UnselectAll ( ) : void |
unselect all weather items
|
|
ZoomTo ( long zipCode ) : void |
Zoom to weather item according to its zipcode
|
|
ZoomTo ( string cityName ) : void |
Zoom to a weather item according to its city name
|
|
get_TipText ( double X, double Y, double Tolerance ) : string |
Map tip text at the specified mouse location.
|
Method | Description | |
---|---|---|
AddWeatherItem ( long zipCode, double Lat, double Lon ) : void |
Makes a request against RSS Weather service and add update the layer's table
|
|
CreateGeographicSpatialReference ( ) : ISpatialReference |
create a WGS1984 geographic coordinate system. In this case, the underlying data provided by the service is in WGS1984.
|
|
DownloadIcon ( string iconPath, int &width, int &height ) : |
given a bitmap url, saves it on the local machine and returns its size
|
|
GetDynamicGlyph ( IDynamicGlyphFactory2 dynamicGlyphFactory, int iconCode, |
||
GetLayerExtent ( ) : IEnvelope |
get the overall extent of the items in the layer
|
|
GetSymbol ( int iconCode, |
get the specified symbol from the symbols table.
|
|
GetSymbolSize ( IDisplay display, int symbolCode ) : double | ||
InitializeLocations ( ) : void |
Initialize the location table. Gets the location from a featureclass
|
|
InitializeSelectionSymbol ( ) : void |
Initialize the symbol that would use to highlight selected items
|
|
InitializeSymbol ( string iconPath, int &iconWidth, int &iconHeight, |
Initialize a character marker symbol for a given bitmap path
|
|
InitializeTables ( ) : void |
initialize the main table used by the layer as well as the symbols table. The base class calles new on the table and adds a default ID field.
|
|
OnUpdateTimer ( object sender, System.Timers.ElapsedEventArgs e ) : void |
run the thread that does the update of the weather data
|
|
PopulateLocationsTableProc ( ) : void |
Load the information from the MajorCities featureclass to the locations table
|
|
SetSymbolSize ( int newSize ) : void | ||
ThreadProc ( ) : void |
the main update thread for the layer. Since the layer gets the weather information from a web service which might take a while to respond, it is not logical to let the application hang while waiting for response. Therefore, running the request on a different thread frees the application to continue working while waiting for a response. Please note that in this case, synchronization of shared resources must be addressed, otherwise you might end up getting unexpected results. |
public AddItem ( long zipCode, double lat, double lon ) : bool | ||
zipCode | long | |
lat | double | |
lon | double | |
return | bool |
public Draw ( esriDrawPhase drawPhase, IDisplay Display, ITrackCancel trackCancel ) : void | ||
drawPhase | esriDrawPhase | |
Display | IDisplay | |
trackCancel | ITrackCancel | |
return | void |
public DrawDynamicLayer ( esriDynamicDrawPhase DynamicDrawPhase, IDisplay Display, IDynamicDisplay DynamicDisplay ) : void | ||
DynamicDrawPhase | esriDynamicDrawPhase | |
Display | IDisplay | |
DynamicDisplay | IDynamicDisplay | |
return | void |
public GetWeatherItem ( long zipCode ) : IPropertySet | ||
zipCode | long | |
return | IPropertySet |
public GetWeatherItem ( string cityName ) : IPropertySet | ||
cityName | string | |
return | IPropertySet |
public Select ( long zipCode, bool newSelection ) : void | ||
zipCode | long | |
newSelection | bool | |
return | void |
public get_TipText ( double X, double Y, double Tolerance ) : string | ||
X | double | |
Y | double | |
Tolerance | double | |
return | string |