鴻蒙OS TableLayoutManager

2022-10-08 09:40 更新

TableLayoutManager

java.lang.Object

|---ohos.agp.components.LayoutManager

|---|---ohos.agp.components.TableLayoutManager

public class TableLayoutManager
extends LayoutManager

表示 ListContainer 對象的表布局管理器。

Since:

5

構造函數(shù)摘要

構造函數(shù) 描述
TableLayoutManager() 用于創(chuàng)建 TableLayoutManager 實例的默認構造函數(shù)。

方法總結

修飾符和類型 方法 描述
int getColumnCount() 獲取表中的列數(shù)。
int getRowCount() 獲取表中的行數(shù)。
void setColumnCount(int columnCount) 設置表中的列數(shù)。
void setRowCount(int rowCount) 設置表中的行數(shù)。
從類 ohos.agp.components.LayoutManager 繼承的方法
getOrientation, setOrientation
從類 java.lang.Object 繼承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

構造函數(shù)詳細信息

TableLayoutManager

public TableLayoutManager()

用于創(chuàng)建 TableLayoutManager 實例的默認構造函數(shù)。

Since:

5

方法詳情

setColumnCount

public void setColumnCount(int columnCount)

設置表中的列數(shù)。

參數(shù):

參數(shù)名稱 參數(shù)描述
columnCount 表示列數(shù)。

Since:

5

getColumnCount

public int getColumnCount()

獲取表中的列數(shù)。

返回:

返回列數(shù)。

Since:

5

setRowCount

public void setRowCount(int rowCount)

設置表中的行數(shù)。

參數(shù):

參數(shù)名稱 參數(shù)描述
rowCount 表示行數(shù)。

Since:

5

getRowCount

public int getRowCount()

獲取表中的行數(shù)。

返回:

返回行數(shù)。

Since:

5

以上內容是否對您有幫助:
在線筆記
App下載
App下載

掃描二維碼

下載編程獅App

公眾號
微信公眾號

編程獅公眾號