• APIブラウザ
  • 設計思想
Show / Hide Table of Contents
  • ExapisSOP
    • AppWorker
    • ContextEventArgs
    • HostRunner
    • IConfiguration
    • IContext
    • IPipeline
    • IProcess
    • IProcess<TParam, TResult>
    • IService
    • TerminationEventArgs
    • TerminationException
    • TerminationReason
    • UnhandledErrorEventArgs
    • VersionInfo
  • ExapisSOP.Binary
    • DataValue
  • ExapisSOP.Core
    • ConfigurationExtensions
    • ContextExtensions
    • CustomPipelineProcess<TParam, TResult>
    • ImmutablePipeline
    • Pipeline
    • PipelineExtensions
    • PipelineExtensions.ExceptionHandler
    • PipelineExtensions.ExceptionHandler<TParam, TResult>
    • PipelineExtensions.LoggingProcess
    • PipelineExtensions.NextProcessFunc
    • PipelineExtensions.ProcessFunc
    • PipelineExtensions.ProcessFunc<TParam, TResult>
    • PipelineExtensions.ProcessFuncWrapper
    • PipelineExtensions.ProcessFuncWrapper<TParam, TResult>
  • ExapisSOP.Globalization
    • EnglishErrorReportBuilder
    • JapaneseErrorReportBuilder
  • ExapisSOP.IO
    • CachedStream
    • DefaultPath
    • FileSystemServiceOptions
    • FileSystemServiceOptionsExtensions
    • IFileSystemService
    • InvalidPathFormatException
    • IPathList
    • Paths
    • PathString
    • PathStringFormatter
  • ExapisSOP.IO.Logging
    • ConsoleLogger
    • DefaultErrorDetailProvider
    • ErrorReportBuilder
    • ExceptionRecord
    • HResultDetailProvider
    • ICustomErrorDetailProvider
    • ILogFile
    • ILoggable
    • ILogger
    • ILoggingSystemService
    • LogData
    • LogFile
    • LogFileType
    • Logger
    • LoggerExtension
    • LoggingSystemServiceOptions
    • LoggingSystemServiceOptions.CreateLogFile
    • LogLevel
    • LongMessageRecord
    • MultipleLogger
    • OutputStreamLogger
  • ExapisSOP.IO.Settings
    • CustomSettings
    • DataStore
    • DefaultSettings
    • EnvironmentSettings
    • ISettingsSystemService
    • OptimizedSettings
    • SettingsSystemServiceOptions
    • SettingsSystemServiceOptions.ConfirmVersionInfo
    • SettingsSystemServiceOptions.GetVersionInfo
  • ExapisSOP.IO.Settings.CommandLine
    • CommandLineConverter
    • CommandLineParser
    • CommandLineServiceOptions
    • CommandLineServiceOptions.CreateConverterMappingTable
    • FileNameList
    • IArgumentConverter
    • IArgumentConverter<T>
    • ICommandLineService
    • ManualAttribute
    • Option
    • Option.Value
    • OptionAttribute
    • Switch
    • SwitchAttribute
  • ExapisSOP.NativeWrapper
    • INativeCaller
    • WinAPI
  • ExapisSOP.NativeWrapper.Windows
    • Kernel32
  • ExapisSOP.Numerics
    • CryptionRandom
    • IRandom
    • LinearCongruentialGenerator
    • RandomExtension
    • SerializableRandom
    • SystemRandom
    • Xorshift
    • Xorshift2
  • ExapisSOP.Text
    • SimpleEncoding
    • SimpleString
  • ExapisSOP.Utils
    • ArrayExtensions
    • ConsoleUtil
    • DisposableBase
    • IAwaitable<T>
    • IAwaiter<T>
    • IUtilityService
    • SecureStringExtensions
    • SerializationInfoExtensions
    • StringExtensions
    • StringUtil
    • UtilityConfigurationExtensions
    • UtilityContextExtensions

ContextExtensions クラス

IContextの機能を拡張します。 このクラスは静的です。

継承
System.Object
ContextExtensions
継承されたメンバー
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
名前空間: ExapisSOP.Core
アセンブリ: ExapisSOP.dll
構文
public static class ContextExtensions

フィールド 一覧

| 編集/提案 ソースを表示

DefaultKeyName

GetData(IContext, String)及び SetData(IContext, String, Object)で 利用される既定のキー名を取得します。

宣言
public const string DefaultKeyName = "_(*)"
フィールド値
型 説明
System.String

メソッド 一覧

| 編集/提案 ソースを表示

GetCommandLine(IContext)

サービスリストから最初に見つかったICommandLineServiceを取得します。

宣言
public static ICommandLineService GetCommandLine(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
ICommandLineService

ICommandLineServiceを実装したサービスオブジェクトです。

| 編集/提案 ソースを表示

GetData(IContext, String)

文脈情報からメッセージデータを取得します。

宣言
public static object GetData(this IContext context, string key)
引数
型 名前 説明
IContext context

現在の文脈情報です。

System.String key

メッセージデータに関連付けられている名前です。

戻り値
型 説明
System.Object

文脈情報に登録されているオブジェクト、または、存在しない場合はnullを返します。

例外
型 条件
System.ArgumentNullException
| 編集/提案 ソースを表示

GetFileSystem(IContext)

サービスリストから最初に見つかったIFileSystemServiceを取得します。

宣言
public static IFileSystemService GetFileSystem(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
IFileSystemService

IFileSystemServiceを実装したサービスオブジェクトです。

| 編集/提案 ソースを表示

GetInitialContext(IContext)

プログラム初期化時に利用された文脈情報を取得します。

宣言
public static IContext GetInitialContext(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
IContext

初期化文脈情報です。 IContextが初期化文脈情報の取得に対応していない場合はnullです。

脚注

カスタム文脈情報からは取得する事はできません。

| 編集/提案 ソースを表示

GetLoggingSystem(IContext)

サービスリストから最初に見つかったILoggingSystemServiceを取得します。

宣言
public static ILoggingSystemService GetLoggingSystem(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
ILoggingSystemService

ILoggingSystemServiceを実装したサービスオブジェクトです。

| 編集/提案 ソースを表示

GetPaths(IContext)

データディレクトリへのパスを格納したオブジェクトを取得します。

宣言
public static Paths GetPaths(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
Paths

PathsをPathsへ変換して返します。 変換に失敗した場合はnullが返ります。

| 編集/提案 ソースを表示

GetPreviousContext(IContext)

前回のイベントループに利用された文脈情報を取得します。

宣言
public static IContext GetPreviousContext(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
IContext

イベントループ文脈情報です。 今回のループが最初の場合はnullを返します。 IContextがイベントループ文脈情報の取得に対応していない場合はnullです。

脚注

カスタム文脈情報からは取得する事はできません。

| 編集/提案 ソースを表示

GetSettingsSystem(IContext)

サービスリストから最初に見つかったISettingsSystemServiceを取得します。

宣言
public static ISettingsSystemService GetSettingsSystem(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
ISettingsSystemService

ISettingsSystemServiceを実装したサービスオブジェクトです。

| 編集/提案 ソースを表示

IsFirstBoot(IContext)

プログラムが初回起動かどうか判定します。

宣言
public static bool? IsFirstBoot(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
System.Nullable<System.Boolean>

初回起動である場合はtrue、 初回起動でない場合はfalse、 判定できなかった場合はnullを返します。

| 編集/提案 ソースを表示

IsMultipleBoot(IContext)

プログラムが多重起動しているかどうか判定します。

宣言
public static bool? IsMultipleBoot(this IContext context)
引数
型 名前 説明
IContext context

現在の文脈情報です。

戻り値
型 説明
System.Nullable<System.Boolean>

多重起動している場合はtrue、 多重起動していない場合はfalse、 判定できなかった場合はnullを返します。

| 編集/提案 ソースを表示

SetData(IContext, String, Object)

文脈情報に指定されたメッセージデータを設定します。 辞書以外のオブジェクトが設定されている場合は上書きされます。 valueがnullの場合、値は削除されます。

宣言
public static void SetData(this IContext context, string key, object value)
引数
型 名前 説明
IContext context

現在の文脈情報です。

System.String key

メッセージデータに関連付ける名前です。

System.Object value

メッセージデータの値です。

例外
型 条件
System.ArgumentNullException
  • 編集/提案
  • ソースを表示
Back to top Generated by DocFX