CTR Pia  4.11.3
Game Communication Engine
session_ISessionInfo.h
1 /*---------------------------------------------------------------------------*
2  Project: Pia
3  File: session_ISessionInfo.h
4 
5  Copyright Nintendo. All rights reserved.
6 
7  These coded instructions, statements, and computer programs contain
8  proprietary information of Nintendo of America Inc. and/or Nintendo
9  Company Ltd., and are protected by Federal copyright law. They may
10  not be disclosed to third parties or copied or duplicated in any form,
11  in whole or in part, without the prior written consent of Nintendo.
12  *---------------------------------------------------------------------------*/
13 
14 
15 #pragma once
16 
17 #include <pia/session/session_definitions.h>
18 
19 namespace nn
20 {
21 namespace pia
22 {
23 namespace session
24 {
25 
26 class SessionStationInfo;
27 
28 
29 /*!
30  @brief An interface to the session's information.
31 */
33 {
34 public:
35  ISessionInfo()
36  {
37  }
38  virtual ~ISessionInfo()
39  {
40  }
41 
42 /*!
43  @brief Gets the session's game mode.
44  @details Returns a game mode value when Internet communication is ongoing.<br />
45  During local communications, a communication mode ID is cast as a <tt>u32</tt> argument and returned.
46  @return Returns the session's game mode.
47 */
48  virtual u32 GetGameMode() const = 0;
49 
50 /*!
51  @brief Gets the session's ID.
52  @return Returns the session ID.
53 */
54  virtual u32 GetSessionId() const = 0;
55 
56 /*!
57  @brief Gets the number of people participating in a session.
58  @return Returns the number of people participating in a session.
59 */
60  virtual u32 GetCurrentParticipants() const = 0;
61 
62 /*!
63  @brief Gets the minimum number of people who can participate in a session.
64  @return Returns the minimum number of people who can participate in a session.
65 */
66  virtual u32 GetMinParticipants() const = 0;
67 
68 /*!
69  @brief Gets the maximum number of people who can participate in a session.
70  @return Returns the maximum number of people who can participate in a session.
71 */
72  virtual u32 GetMaxParticipants() const = 0;
73 
74 /*!
75  @brief Gets whether a session is open for recruitment.
76  @return Returns <tt>true</tt> if the session is open for recruitment, and returns <tt>false</tt> if it is closed.
77 */
78  virtual bool IsOpened() const = 0;
79 
80 /*!
81  @brief Clears session information.
82 */
83  virtual void Clear() = 0;
84 
85 /*!
86  @brief Prints information that is useful for debugging.
87  @param[in] flag Specifies the bitwise OR of trace flags. For more information, see the <tt>@ref TraceFlag</tt> API reference.
88 */
89  virtual void Trace(u64 flag) = 0;
90 
91 };
92 }
93 }
94 } // end of namespace nn::pia::session
virtual void Trace(u64 flag)=0
Prints information that is useful for debugging.
virtual u32 GetGameMode() const =0
Gets the session&#39;s game mode.
virtual bool IsOpened() const =0
Gets whether a session is open for recruitment.
Definition: assert.h:115
virtual void Clear()=0
Clears session information.
virtual u32 GetMaxParticipants() const =0
Gets the maximum number of people who can participate in a session.
An interface to the session&#39;s information.
Definition: session_ISessionInfo.h:32
virtual u32 GetMinParticipants() const =0
Gets the minimum number of people who can participate in a session.
virtual u32 GetCurrentParticipants() const =0
Gets the number of people participating in a session.
This is the common base class used inside the Pia library.
Definition: common_RootObject.h:40
virtual u32 GetSessionId() const =0
Gets the session&#39;s ID.