From 1b7db68f900dca1a4704d5715d748399854318e1 Mon Sep 17 00:00:00 2001 From: Michal Bloch Date: Tue, 16 Jun 2026 16:01:38 +0200 Subject: [PATCH 1/3] Annotate Session functions with `since_tizen` --- src/Tizen.System.Session/Session/Session.cs | 14 +++++++++++- .../Session/SessionEventArgs.cs | 22 ++++++++++++++----- 2 files changed, 30 insertions(+), 6 deletions(-) diff --git a/src/Tizen.System.Session/Session/Session.cs b/src/Tizen.System.Session/Session/Session.cs index cf09d03628b..97e3d47763f 100644 --- a/src/Tizen.System.Session/Session/Session.cs +++ b/src/Tizen.System.Session/Session/Session.cs @@ -28,6 +28,7 @@ namespace Tizen.System /// /// Provides methods to manage subsession users. Allows to register for events triggered by operations on subsession users. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public sealed class Session { @@ -40,12 +41,14 @@ public sealed class Session /// /// Maximum length of any given user ID. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public const int MaxUserLength = 20; /// /// Special subsession ID, which is always present and does not represent any user. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public const string EmptyUser = ""; @@ -77,6 +80,7 @@ private Session(int sessionUID) /// /// To ensure thread safety, explicit creation of Session object is not allowed. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public static Session GetInstance(int sessionUID) { @@ -88,6 +92,7 @@ public static Session GetInstance(int sessionUID) /// /// Gets session UID of this session object. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public int SessionUID { get; private set; } @@ -107,6 +112,7 @@ public static Session GetInstance(int sessionUID) /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public IReadOnlyList GetUsers() { @@ -137,6 +143,7 @@ public IReadOnlyList GetUsers() /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public string GetCurrentUser() { @@ -286,12 +293,13 @@ public Task SubsessionSwitchUserAsync(string userName) /// Event argument of the event (obtained from said event) /// /// This method is assumed to be called from an event handler. You can only mark an event as completed - /// if you registered for in in the same process. + /// if you registered for it in the same process. /// /// Session UID of this object is invalid /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public void SubsessionEventMarkAsDone(SubsessionEventArgs subsessionEventArgs) { @@ -318,6 +326,7 @@ private void OnAddUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler AddUserWait { @@ -360,6 +369,7 @@ private void OnRemoveUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler RemoveUserWait { @@ -402,6 +412,7 @@ private void OnSwitchUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler SwitchUserWait { @@ -444,6 +455,7 @@ private void OnSwitchUserCompletion(SubsessionEventInfoNative infoNative, IntPtr /// Internal error /// Not permitted /// Not supported + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler SwitchUserCompleted { diff --git a/src/Tizen.System.Session/Session/SessionEventArgs.cs b/src/Tizen.System.Session/Session/SessionEventArgs.cs index 57333b78991..2eda7914b53 100644 --- a/src/Tizen.System.Session/Session/SessionEventArgs.cs +++ b/src/Tizen.System.Session/Session/SessionEventArgs.cs @@ -28,12 +28,14 @@ namespace Tizen.System /// You can check the event type that was invoked by checking a type of event arguments /// during runtime - they all derive from this base class. /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public abstract class SubsessionEventArgs : EventArgs { /// /// Session UID of the session invoking the event /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public int SessionUID { get; internal set; } @@ -50,12 +52,14 @@ internal SubsessionEventArgs(SubsessionEventInfoNative eventInfo) /// /// An event argument type for AddUserWait event type /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public class AddUserEventArgs : SubsessionEventArgs { /// /// Added subsession user ID - /// + /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public string UserName { get; internal set; } @@ -75,12 +79,14 @@ internal AddUserEventArgs(SubsessionEventInfoNative eventInfo) /// /// An event argument type for RemoveUserWait event type /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public class RemoveUserEventArgs : SubsessionEventArgs { /// /// Removed subsession user ID - /// + /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public string UserName { get; internal set; } @@ -99,24 +105,28 @@ internal RemoveUserEventArgs(SubsessionEventInfoNative eventInfo) /// /// A generic base class for Switch event types /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public abstract class SwitchUserEventArgs : SubsessionEventArgs { /// /// ID of this switch operation - /// + /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public long SwitchID { get; internal set; } /// /// Active subsession user ID before this switch operation - /// + /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public string UserNamePrev { get; internal set; } /// /// Active subsession ID after this switch operation - /// + /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public string UserNameNext { get; internal set; } @@ -141,6 +151,7 @@ internal SwitchUserEventArgs(SubsessionEventInfoNative eventInfo) /// /// An event argument type for SwitchUserWait event type /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public class SwitchUserWaitEventArgs : SwitchUserEventArgs { @@ -150,6 +161,7 @@ internal SwitchUserWaitEventArgs(SubsessionEventInfoNative eventInfo) : base(eve /// /// An event argument type for SwitchUserCompleted event type /// + /// 10.1 [EditorBrowsable(EditorBrowsableState.Never)] public class SwitchUserCompletionEventArgs : SwitchUserEventArgs { From 0a5c2a56494d0bf3fc62bc7da35c948c496a6fb7 Mon Sep 17 00:00:00 2001 From: Michal Bloch Date: Tue, 16 Jun 2026 17:56:09 +0200 Subject: [PATCH 2/3] Make Session API partially public See ACR-1952. --- src/Tizen.System.Session/Session/Session.cs | 12 ------------ src/Tizen.System.Session/Session/SessionEventArgs.cs | 12 ------------ 2 files changed, 24 deletions(-) diff --git a/src/Tizen.System.Session/Session/Session.cs b/src/Tizen.System.Session/Session/Session.cs index 97e3d47763f..14a8c0a5638 100644 --- a/src/Tizen.System.Session/Session/Session.cs +++ b/src/Tizen.System.Session/Session/Session.cs @@ -29,7 +29,6 @@ namespace Tizen.System /// Provides methods to manage subsession users. Allows to register for events triggered by operations on subsession users. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public sealed class Session { /// @@ -42,14 +41,12 @@ public sealed class Session /// Maximum length of any given user ID. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public const int MaxUserLength = 20; /// /// Special subsession ID, which is always present and does not represent any user. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public const string EmptyUser = ""; private static ConcurrentDictionary s_sessionInstances = new ConcurrentDictionary(); @@ -81,7 +78,6 @@ private Session(int sessionUID) /// To ensure thread safety, explicit creation of Session object is not allowed. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public static Session GetInstance(int sessionUID) { if (!s_sessionInstances.ContainsKey(sessionUID)) @@ -93,7 +89,6 @@ public static Session GetInstance(int sessionUID) /// Gets session UID of this session object. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public int SessionUID { get; private set; } /// @@ -113,7 +108,6 @@ public static Session GetInstance(int sessionUID) /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public IReadOnlyList GetUsers() { @@ -144,7 +138,6 @@ public IReadOnlyList GetUsers() /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public string GetCurrentUser() { StringBuilder user = new StringBuilder(MaxUserLength); @@ -300,7 +293,6 @@ public Task SubsessionSwitchUserAsync(string userName) /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public void SubsessionEventMarkAsDone(SubsessionEventArgs subsessionEventArgs) { SessionError ret = Interop.Session.SubsessionEventWaitDone(subsessionEventArgs.SessionInfo); @@ -327,7 +319,6 @@ private void OnAddUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler AddUserWait { add @@ -370,7 +361,6 @@ private void OnRemoveUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler RemoveUserWait { add @@ -413,7 +403,6 @@ private void OnSwitchUserWait(SubsessionEventInfoNative infoNative, IntPtr data) /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler SwitchUserWait { add @@ -456,7 +445,6 @@ private void OnSwitchUserCompletion(SubsessionEventInfoNative infoNative, IntPtr /// Not permitted /// Not supported /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public event EventHandler SwitchUserCompleted { add diff --git a/src/Tizen.System.Session/Session/SessionEventArgs.cs b/src/Tizen.System.Session/Session/SessionEventArgs.cs index 2eda7914b53..291f60f8c58 100644 --- a/src/Tizen.System.Session/Session/SessionEventArgs.cs +++ b/src/Tizen.System.Session/Session/SessionEventArgs.cs @@ -29,14 +29,12 @@ namespace Tizen.System /// during runtime - they all derive from this base class. /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public abstract class SubsessionEventArgs : EventArgs { /// /// Session UID of the session invoking the event /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public int SessionUID { get; internal set; } internal SubsessionEventInfoNative SessionInfo { get; set; } @@ -53,14 +51,12 @@ internal SubsessionEventArgs(SubsessionEventInfoNative eventInfo) /// An event argument type for AddUserWait event type /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public class AddUserEventArgs : SubsessionEventArgs { /// /// Added subsession user ID /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public string UserName { get; internal set; } internal AddUserEventArgs(SubsessionEventInfoNative eventInfo) @@ -80,14 +76,12 @@ internal AddUserEventArgs(SubsessionEventInfoNative eventInfo) /// An event argument type for RemoveUserWait event type /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public class RemoveUserEventArgs : SubsessionEventArgs { /// /// Removed subsession user ID /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public string UserName { get; internal set; } internal RemoveUserEventArgs(SubsessionEventInfoNative eventInfo) @@ -106,28 +100,24 @@ internal RemoveUserEventArgs(SubsessionEventInfoNative eventInfo) /// A generic base class for Switch event types /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public abstract class SwitchUserEventArgs : SubsessionEventArgs { /// /// ID of this switch operation /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public long SwitchID { get; internal set; } /// /// Active subsession user ID before this switch operation /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public string UserNamePrev { get; internal set; } /// /// Active subsession ID after this switch operation /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public string UserNameNext { get; internal set; } internal SwitchUserEventArgs(SubsessionEventInfoNative eventInfo) @@ -152,7 +142,6 @@ internal SwitchUserEventArgs(SubsessionEventInfoNative eventInfo) /// An event argument type for SwitchUserWait event type /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public class SwitchUserWaitEventArgs : SwitchUserEventArgs { internal SwitchUserWaitEventArgs(SubsessionEventInfoNative eventInfo) : base(eventInfo) { } @@ -162,7 +151,6 @@ internal SwitchUserWaitEventArgs(SubsessionEventInfoNative eventInfo) : base(eve /// An event argument type for SwitchUserCompleted event type /// /// 10.1 - [EditorBrowsable(EditorBrowsableState.Never)] public class SwitchUserCompletionEventArgs : SwitchUserEventArgs { internal SwitchUserCompletionEventArgs(SubsessionEventInfoNative eventInfo) : base(eventInfo) { } From eea3df8997ebb4b7bfcabdb6e8da41796a3852e8 Mon Sep 17 00:00:00 2001 From: Michal Bloch Date: Fri, 19 Jun 2026 14:03:44 +0200 Subject: [PATCH 3/3] Sessiond API: add tags. --- src/Tizen.System.Session/Session/Session.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Tizen.System.Session/Session/Session.cs b/src/Tizen.System.Session/Session/Session.cs index 14a8c0a5638..ead4424b190 100644 --- a/src/Tizen.System.Session/Session/Session.cs +++ b/src/Tizen.System.Session/Session/Session.cs @@ -107,6 +107,7 @@ public static Session GetInstance(int sessionUID) /// Internal error /// Not permitted /// Not supported + /// A read-only list of all subsession IDs for this session. /// 10.1 public IReadOnlyList GetUsers() { @@ -137,6 +138,7 @@ public IReadOnlyList GetUsers() /// Internal error /// Not permitted /// Not supported + /// The currently active subsession user ID, or "" (EmptyUser) when no subsession is enabled. /// 10.1 public string GetCurrentUser() {