Class MonumentAsset
- Namespace
- RustMapsApi.V4.Assets
- Assembly
- RustMapsApi.Assets.dll
A monument icon asset (SVG) resolved from a MonumentType.
public sealed class MonumentAsset
- Inheritance
-
MonumentAsset
- Inherited Members
Properties
AssetName
The RustMaps CDN base name of the asset, e.g. "Nuclear_Missile_Silo".
public string AssetName { get; }
Property Value
FileName
The asset file name, e.g. "Nuclear_Missile_Silo.svg".
public string FileName { get; }
Property Value
MediaType
The MIME media type of the asset — always "image/svg+xml".
public string MediaType { get; }
Property Value
MonumentType
The monument type this asset was resolved for.
public MonumentType MonumentType { get; }
Property Value
SourceUri
The canonical RustMaps CDN URL this asset was sourced from.
public Uri SourceUri { get; }
Property Value
Methods
GetBytes()
Reads the full SVG as a byte array.
public byte[] GetBytes()
Returns
- byte[]
The SVG bytes.
GetSvg()
Reads the full SVG markup as a UTF-8 string.
public string GetSvg()
Returns
- string
The SVG markup.
OpenStream()
Opens a new read stream over the embedded SVG. The caller owns and disposes it.
public Stream OpenStream()
Returns
- Stream
A readable stream of the SVG bytes.
Exceptions
- InvalidOperationException
The embedded monument asset resource was not found.