Instance Method インスタンスメソッド

enableAutomaticTermination:

Enables automatic termination for the application. アプリケーションに自動終了を利用可能にします。

Declaration 宣言

- (void)enableAutomaticTermination:(NSString *)reason;

Parameters パラメータ

reason

The reason why automatic termination is being enabled. なぜ自動終了が可能にされているかの理由。

Discussion 議論

This method decrements the automatic termination counter. When the counter is 0, the application is eligible for automatic termination. このメソッドは、自動終了カウンタを漸減します。カウンタが0である場合、アプリケーションは自動終了に対して適格です。

The reason parameter is used to track why an application is or is not automatically terminable and can be inspected by debugging tools. For example, you could pass the string @"file transfer in progress" if you disable automatic termination before transferring a file over the network. When you reenable automatic termination after the transfer is complete using enableAutomaticTermination:, you should pass the matching string. A given reason can be used more than once at the same time; for example, if two files were being transferred at the same time, automatic termination could be disabled for each, passing the same reason string. reasonパラメータは、あるアプリケーションが自動終了可能であるまたはでない理由を追跡するために使われます、そしてデバッグツールによって調査されることが可能です。例えば、あなたは文字列@"file transfer in progress"を渡すことができます、もしあなたがファイルをネットワーク越しに転送する前に自動終了を作動しないようにするならば。あなたが自動終了をその転送が完了した後にenableAutomaticTermination:を使って再度利用可能にする場合、あなたは調和する文字列を渡すべきです。与えられた理由は、一度に一度以上使用できます;例えば、2つのファイルが一度に転送していたならば、自動終了はそれぞれに対して、同じ理由文字列を渡して利用できなくされることが可能です。

See Also 参照

Controlling Automatic Termination 自動終了を制御する