C# Class Sharpcraft.Steam.SteamFriendList

Class for managing Steam friends.
Exibir arquivo Open project: SijmenSchoon/Sharpcraft Class Usage Examples

Public Methods

Method Description
GetFriendByName ( string name ) : SteamFriend

Get a friend by their name (alias).

Note that the name (alias) can change frequently, do not rely on the name to keep track of friends.

GetFriendBySteamId ( string id ) : SteamFriend

Get a friend by their SteamID.

GetFriendCount ( bool online = false ) : int

Get number of Steam friends.

GetFriends ( ) : IEnumerable

Return the list of Steam friends.

Private Methods

Method Description
FriendsUpdate ( SteamFriendsEventArgs e ) : void

Method called from SteamFriendList that fires OnFriendsUpdate.

LoadFriends ( ) : void

Load all Steam friends into list.

SteamClose ( ) : void

Handler for SteamClose event, disposes timer and clears friend list.

SteamFriendList ( ) : System.Collections.Generic

Initialize a new SteamFriendList.

Update ( object state ) : void

Updates the friend list.

Method Details

GetFriendByName() public method

Get a friend by their name (alias).
Note that the name (alias) can change frequently, do not rely on the name to keep track of friends.
public GetFriendByName ( string name ) : SteamFriend
name string The name (alias) to look up.
return SteamFriend

GetFriendBySteamId() public method

Get a friend by their SteamID.
public GetFriendBySteamId ( string id ) : SteamFriend
id string representation of the friend's SteamID.
return SteamFriend

GetFriendCount() public method

Get number of Steam friends.
public GetFriendCount ( bool online = false ) : int
online bool Whether or not to only return the number of online friends.
return int

GetFriends() public method

Return the list of Steam friends.
public GetFriends ( ) : IEnumerable
return IEnumerable