Table of Contents

Class AppTeamInfoToModel

Namespace
RustPlusApi.Extensions
Assembly
RustPlusApi.dll

Mapping extensions from protobuf team-info messages to model types.

public static class AppTeamInfoToModel
Inheritance
AppTeamInfoToModel
Inherited Members

Methods

ToDeathNote(Note)

Maps a type-0 protobuf note to a DeathNote.

public static DeathNote ToDeathNote(this AppTeamInfo.Note note)

Parameters

note AppTeamInfo.Note

The protobuf map note.

Returns

DeathNote

ToMemberInfo(Member)

Maps a single protobuf team member to a MemberInfo.

public static MemberInfo ToMemberInfo(this AppTeamInfo.Member member)

Parameters

member AppTeamInfo.Member

The protobuf team member.

Returns

MemberInfo

ToMemberInfos(IEnumerable<Member>)

Maps a sequence of protobuf team members to MemberInfo instances.

public static IEnumerable<MemberInfo> ToMemberInfos(this IEnumerable<AppTeamInfo.Member> members)

Parameters

members IEnumerable<AppTeamInfo.Member>

The protobuf team members to map.

Returns

IEnumerable<MemberInfo>

ToPlayerNote(Note)

Maps a type-1 protobuf note to a PlayerNote.

public static PlayerNote ToPlayerNote(this AppTeamInfo.Note note)

Parameters

note AppTeamInfo.Note

The protobuf map note.

Returns

PlayerNote

ToPlayerNotes(IEnumerable<Note>)

Maps a sequence of protobuf notes to PlayerNote instances.

public static IEnumerable<PlayerNote> ToPlayerNotes(this IEnumerable<AppTeamInfo.Note> notes)

Parameters

notes IEnumerable<AppTeamInfo.Note>

The protobuf notes to map.

Returns

IEnumerable<PlayerNote>

ToTeamInfo(AppTeamInfo)

Maps an RustPlusContracts.AppTeamInfo to a TeamInfo, routing map notes to typed models.

public static TeamInfo ToTeamInfo(this AppTeamInfo appTeamInfo)

Parameters

appTeamInfo AppTeamInfo

The protobuf team info response.

Returns

TeamInfo

Exceptions

ArgumentException

Thrown when a map note has an unrecognized type.