IComponentType

Type
Interface
Namespace
Craft
Implemented by
Craft\AssetElementType, Craft\AssetIndexTool, Craft\AssetsFieldType, Craft\BaseAssetSourceType, Craft\BaseComponentType, Craft\BaseElementAction, Craft\BaseElementFieldType, Craft\BaseElementType, Craft\BaseFieldType, Craft\BaseOptionsFieldType, Craft\BasePlugin, Craft\BaseSavableComponentType, Craft\BaseTask, Craft\BaseTool, Craft\BaseWidget, Craft\CategoriesFieldType, Craft\CategoryElementType, Craft\CheckboxesFieldType, Craft\ClearCachesTool, Craft\ColorFieldType, Craft\CopyReferenceTagElementAction, Craft\DateFieldType, Craft\DbBackupTool, Craft\DeleteAssetsElementAction, Craft\DeleteElementAction, Craft\DeleteStaleTemplateCachesTask, Craft\DeleteUsersElementAction, Craft\DownloadFileElementAction, Craft\DropdownFieldType, Craft\EditElementAction, Craft\EntriesFieldType, Craft\EntryElementType, Craft\FeedWidget, Craft\FindAndReplaceTask, Craft\FindAndReplaceTool, Craft\GeneratePendingTransformsTask, Craft\GetHelpWidget, Craft\GlobalSetElementType, Craft\GoogleCloudAssetSourceType, Craft\IElementAction, Craft\IElementType, Craft\ISavableComponentType, Craft\ITool, Craft\LightswitchFieldType, Craft\LocalAssetSourceType, Craft\LocalizeRelationsTask, Craft\MatrixBlockElementType, Craft\MatrixFieldType, Craft\MultiSelectFieldType, Craft\NewChildElementAction, Craft\NewUsersWidget, Craft\NumberFieldType, Craft\PlainTextFieldType, Craft\PositionSelectFieldType, Craft\QuickPostWidget, Craft\RackspaceAssetSourceType, Craft\RadioButtonsFieldType, Craft\RecentEntriesWidget, Craft\RenameFileElementAction, Craft\ReplaceFileElementAction, Craft\ResaveAllElementsTask, Craft\ResaveElementsTask, Craft\RichTextFieldType, Craft\S3AssetSourceType, Craft\SearchIndexTool, Craft\SetStatusElementAction, Craft\SuspendUsersElementAction, Craft\TableFieldType, Craft\TagElementType, Craft\TagsFieldType, Craft\TempAssetSourceType, Craft\UnsuspendUsersElementAction, Craft\UpdateElementSlugsAndUrisTask, Craft\UpdatesWidget, Craft\UserElementType, Craft\UsersFieldType, Craft\ViewElementAction
Since
1.0

Component type interface.

See also http://craftcms.com

View source (opens new window)

# Public Methods

Method Description
getClassHandle() Returns the component’s handle, ideally based on the class name.
getName() Returns the component’s name.
isSelectable() Returns whether this component should be shown when the user is creating a component of this type.

# getClassHandle()

Returns the component’s handle, ideally based on the class name.

View source (opens new window)

Returns

string (opens new window) – The component’s handle.

Signature

public abstract string getClassHandle ( )

# getName()

Returns the component’s name. This is what your component will be called throughout the Control Panel.

View source (opens new window)

Returns

string (opens new window) – The component’s name.

Signature

public abstract string getName ( )

# isSelectable()

Returns whether this component should be shown when the user is creating a component of this type.

View source (opens new window)

Returns

boolean (opens new window) – Whether the component should be selectable.

Signature

public abstract boolean isSelectable ( )