UITableView.DequeueReusableCell メソッド

定義

オーバーロード

DequeueReusableCell(NSString)

指定した ReuseIdentifier で作成された再利用可能なテーブル ビュー セルを返します。

DequeueReusableCell(String)

指定した ReuseIdentifier で作成された再利用可能なテーブル ビュー セルを返します。

DequeueReusableCell(NSString, NSIndexPath)

指定reuseIdentifierされた の再利用可能なテーブル ビュー セルを返します。適切なサイズの 。indexPath

DequeueReusableCell(String, NSIndexPath)

reuseIdentifier 識別され、 にある再利用可能なセルを indexPath返します。

DequeueReusableCell(NSString)

指定した ReuseIdentifier で作成された再利用可能なテーブル ビュー セルを返します。

public UIKit.UITableViewCell DequeueReusableCell (Foundation.NSString identifier);
member this.DequeueReusableCell : Foundation.NSString -> UIKit.UITableViewCell

パラメーター

identifier
NSString

要求されているセルの種類を識別する文字列。

戻り値

UITableViewCellidentifier関連付けられている 。またはnull、その特定identifierの を持つセルがキューに存在しない場合は 。

注釈

セル再利用キャッシュは効率を高める上で重要であり、アプリケーション開発者は動的テーブルに使用する必要があります。

iOS 6 以降を対象とするアプリケーション開発者は、 または をRegisterNibForCellReuse(UINib, String)使用RegisterClassForCellReuse(Type, String)する必要があります。 クラスが UITableViewCell 登録されると、 を DequeueReusableCell(String, NSIndexPath) 呼び出すと、 が返されるのではなく、必要に応じて新しくインスタンス化されたオブジェクトが null返されます。

アプリケーション開発者は、 の使用 DequeueReusableCell(NSString, NSIndexPath)を優先する必要があります。これは、インデックス パスに合わせて適切なサイズの を UITableViewCell 返します。

こちらもご覧ください

  • <xref:UIKit.UITableView.RegisterClassForCellReuse>
  • <xref:UIKit.UITableView.RegisterNibForCellReuse>

適用対象

DequeueReusableCell(String)

指定した ReuseIdentifier で作成された再利用可能なテーブル ビュー セルを返します。

[Foundation.Export("dequeueReusableCellWithIdentifier:")]
public virtual UIKit.UITableViewCell DequeueReusableCell (string identifier);
abstract member DequeueReusableCell : string -> UIKit.UITableViewCell
override this.DequeueReusableCell : string -> UIKit.UITableViewCell

パラメーター

identifier
String

要求されているセルの種類を識別する文字列。

戻り値

UITableViewCellidentifier関連付けられている 。またはnull、その特定identifierの を持つセルがキューに存在しない場合は 。

属性

注釈

セル再利用キャッシュは効率を高める上で重要であり、アプリケーション開発者は動的テーブルに使用する必要があります。

iOS 6 以降を対象とするアプリケーション開発者は、 または をRegisterNibForCellReuse(UINib, String)使用RegisterClassForCellReuse(Type, String)する必要があります。 クラスが UITableViewCell 登録されると、 を DequeueReusableCell(String, NSIndexPath) 呼び出すと、 が返されるのではなく、必要に応じて新しくインスタンス化されたオブジェクトが null返されます。

アプリケーション開発者は、 の使用 DequeueReusableCell(NSString, NSIndexPath)を優先する必要があります。これは、インデックス パスに合わせて適切なサイズの を UITableViewCell 返します。

こちらもご覧ください

  • <xref:UIKit.UITableView.RegisterClassForCellReuse>
  • <xref:UIKit.UITableView.RegisterNibForCellReuse>

適用対象

DequeueReusableCell(NSString, NSIndexPath)

指定reuseIdentifierされた の再利用可能なテーブル ビュー セルを返します。適切なサイズの 。indexPath

[Foundation.Export("dequeueReusableCellWithIdentifier:forIndexPath:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual UIKit.UITableViewCell DequeueReusableCell (Foundation.NSString reuseIdentifier, Foundation.NSIndexPath indexPath);
abstract member DequeueReusableCell : Foundation.NSString * Foundation.NSIndexPath -> UIKit.UITableViewCell
override this.DequeueReusableCell : Foundation.NSString * Foundation.NSIndexPath -> UIKit.UITableViewCell

パラメーター

reuseIdentifier
NSString

要求されているセルの種類を識別する文字列。

indexPath
NSIndexPath

要求されている特定のセル。

戻り値

UITableViewCell に関連付けられている identifier

属性

注釈

これは、 を呼び出して適切なサイズの を返すので、セルの再利用を呼び出 GetHeightForRow(UITableView, NSIndexPath) すために推奨されるメソッドです UITableViewCell

このメソッドの前には、 または RegisterNibForCellReuse(UINib, String)を使用したセル登録がRegisterClassForCellReuse(Type, String)必要です。 それ以外の場合は、実行時に NSInternalInconsistencyException 例外が発生します。

セル再利用キャッシュは効率を高める上で重要であり、アプリケーション開発者は動的テーブルに使用する必要があります。

こちらもご覧ください

  • <xref:UIKit.UITableView.RegisterClassForCellReuse>
  • <xref:UIKit.UITableView.RegisterNibForCellReuse>

適用対象

DequeueReusableCell(String, NSIndexPath)

reuseIdentifier 識別され、 にある再利用可能なセルを indexPath返します。

public UIKit.UITableViewCell DequeueReusableCell (string reuseIdentifier, Foundation.NSIndexPath indexPath);
member this.DequeueReusableCell : string * Foundation.NSIndexPath -> UIKit.UITableViewCell

パラメーター

reuseIdentifier
String
indexPath
NSIndexPath

戻り値

適用対象