52. 字段API(中)

龸龴api龪龩龧龦龸龴龥龡龠龸龴龞龛龠龸龴龘龕龓龑龏龎龌龊龇龄龃龁齽齼龸龴龥龡龇龪龸龴齹齸齵齲齯齫齨齤齢齞龪龸龴齜齫齨齘龇龪齔齐龏齍齋齈齅齂鼾龪鼼龡龏龸龴龥龡齋齂鼹齔齘鼸龪鼵鼸龓齫齨龥龡龏鼴鼲鼱鼮鼬龥龡鼪龦鼲鼩龏齔齘龇龪鼨齂鼹鼦鼤齋齂鼹鼢鼞鼵鼸龪鼵鼸龓齫齨龥龡龏鼚鼖鼔鼐龸龴鼦鼤龥龡龏龸龴龥龡齋齔齘龥龡鼎鼋鼊龸龴鼚鼖齋鼈鼅龪龏鼄鼃鼀齋龦黼黺黸黶龎黲黰黭黩龸龴黲黰龇鼚鼖黦鼋齫黥黤黡龪點黜龏龸龴鼦鼤龥龡齋齂鼹鼢鼞鼵鼸龪鼵鼸龓齫齨龥龡龏黚黺齍鼚鼖默鼈鼹鼲鼩龏鼄黔鼲鼩黐鼋齸龎龸龴鼦鼤龥龡龪schema黅黄龇齜龎黂黀麽齫麹龪columns麮龇麬鼋齐龏鼄鼃鼀齋龦黼黺默黔龸龴龥龡鼚鼖麫麧鼈鼹齫齨龪點黜龏麣鼸龪齋麡麠龇龪body龸龴龏齍麙麕麒麑龠麏麌龠龘龕麊鼹鼲鼩龏鼄黔鼲鼩龇默齂鼹鼐龦龸龴龥龡龪麉鼲鼩龏龥麆龪鼀齋鼢鼞齫齨鼋齸龥龡龇龪getMainPropertyName()黅黄黀麽龪鹳龸鹰鹮鹫鼖龌龪鹧鹣龎鹢鹡龇鹟鹜麌鹘鹕鹑鼹鹏鹋鹇鼈鼅龸龴龠鼈鼲鼩龸龴龏龎齫齨齤龪麫麧齢齞龏鼚鼖鼈鼹龸龴龥龡鹅麧齯齂鹃齘龇龏鼄鹁龪齘鼔鼐鹅鸾齘龏鼃鼚鼖齂鼹龸龴齂鹃齘龏鼄鹁龪齘鼔鼐龸龴鸽鸺齘鸸龎齘龇齂鼹龸龴龥龡鼚鼖鸶默鼈鼹齔鼖鸵鸲麫麧齍龪鼲鼩齫齨龏鸮鼮龌黸黶龎黲黰黭黩鼋齸龪龸龴鸫齋麫麧龎鸽鸺齘龇龏齂鼹龸龴齂鹃齫齨齘龏鸨齯鸤鸢麫麧鸡龎鼮鼬麫麧鸞黰龑龇鸛鸙鸘鸖鹰龸龴龥龡龪鸔鸒鼮鸎鸤鸋鹇

龸龴龥龡齋鼵鼸龓API齫齨鸄鸀龇龪齔齘齫齨龥龡龏鷾龪鷻鷹鼮鸎龦鹇

Drupal\Core\Field\FieldItemList

齜鷤鷣鹇Drupal\Core\Field\FieldItemListInterface齐

黂鼋齸龥龡龦鹇

Drupal\Core\Field\BaseFieldDefinition

齜鷤鷣鹇Drupal\Core\Field\FieldDefinitionInterface齐

齔齘龇龪鷜鷛齋齂鼹鼢鼞齫齨龥龡龏鷻鷹鼮鸎龦鹇

Drupal\Core\Field\FieldItemBase

齜鷾齋鼼龡鸔鼵龏鷘鷖鷓鷐龸龴鷎龛鷊鷆龏黂鷤鷣鹇\Drupal\Core\Field\FieldItemInterface齐

黂鼋齸龥龡龦鹇

Drupal\Core\Field\TypedData\FieldItemDataDefinition

齜鷤鷣鹇Drupal\Core\TypedData\ComplexDataDefinitionInterface龏鶿鶼鼄鶻鶹鷤鼮鸎齼鼢鼞齫齨鼋齸鷤鷣齐

龸龴龥龡龪龩龧鶶鶲鼀齋鶱鶰鼖龌鶮鼹鼵鶪鶦龏鷐鼵鼸龸龴龥龡鼖鷎龛黅龕鷘鷖龏鷾黶鶢鼈鷊鷆鶠鹇

Drupal\Core\Field\FieldItemBase

龦齼黲黰鼄黔鷎龛麡麠鷘鷖齼龸龴鼵鼸鷎龛黲黰龑龏鶜鸋鹇

龸龴鼵鼸鷎龛黲黰龑鹇

鶲龑鶛鶙id鹇plugin.manager.field.field_type

鶍鶉黅龕鹇\Drupal::service('plugin.manager.field.field_type')

鷎龛鼋齸鵺麧鵷鵶鹇鵺麧齘cache_discovery 龪field_types_plugins鼦鼤

鷎龛麫麧鵷鵶鹇Plugin/Field/FieldType

鵰鵯鵭鵪鹳鹇field_info

龸龴鼵鼸鼵鹜麌鼮鸎龪鷤鷣鹇Drupal\Core\Field\FieldItemInterface

龸龴鼵鼸鷎龛鸺鼱齼鷎龛鸵鼵鵧鵥龏黜鵤鵢鷎龛黲黰龑鼮鸎齼鼖鸋鷤鷣鹇

Drupal\Component\Plugin\CategorizingPluginManagerInterface

麡麠鷘鷖鼖鸋鵜鵙鼖鼮鸎鵢鸵鼵鷤鷣鹇

Drupal\Core\Plugin\CategorizingPluginManagerTrait;

鸨齯鷎龛鸵鼵鸛鶜鵔麡齔龪鷎龛麉鵐鸋龊龏鶶鶲鵎鵌鵋鵉

龸龴鼵鼸鷎龛鵅鵄鼪龦齂鵀鼵鼸龓齫齨鷎龛龏黜鵤龎鼵鼸龓鷎龛黲黰龑龇鹮鹫鷎龛鴾鴺齜鴹鴺齐Plugin derivatives鴷黡鸡龸龴鼵鼸鷎龛鴳鴱鼱齼鼵鼸龓鷎龛龏鴮鹜麌鶿鶼龎鼵鼸龓鷎龛黲黰龑龇龪鷎龛id龦鹇

鴬field_item:鴩 + 龸龴鼵鼸鷎龛黲黰龑龇鼵鼸id

鼃鼀齋"field_item:FIELD_TYPE"鴜龕龏齵麌鴚鴖鴔齼龏鷎龛鴾鴺鸛鶜鵔麡齔龪鷎龛麉鵐龇龊鹰

龸龴鼵鼸鶠鼋齸鹇

鼋齸齂鼹鼵鹳鼖Item鸄鴐龪鼵齜鼄齋鴎鴍鴊鴇鼮鴄龏鴁鳿龁黡龪鳾鹳黅黄齐龏鳺鵶龎鳶鳲龪Plugin/Field/FieldType鼤鳱鸋龏鵢鼵鳰鳮鼮鸎鼖鸋鷤鷣鹇

Drupal\Core\Field\FieldItemInterface

鼚鳫鷊鷆鸔鼵Drupal\Core\Field\FieldItemBase龏鵢鸔鼵龄龃鼮鸎齼鼖龌鷤鷣龏鷊鷆鵄鼚齵鳩鳨鷤鷣龏鸺鳦鳤鹜麌鼚鳫龪鳢鳞黅黄鳚鳖鳒鸖麑鼋齸鳑鼚龏黅黄龪鳐鳨鳎鳍鳌鷤鷣龏鼄鶻齔鳋鸖麑龇龪齂黔麮龪齹齸鹇

Category鹇齘鳊龸龴鼵鼸龪鸵鼵龏龎黭黩鳈鳆龸龴鵄鳅鳌鼱鳁鳀黦鵶龠鲾鸺龠齫龸龠麑鵔鲻鶢鼵鸵鼵龏鸤鲷齵黦鵶鷻鷹龦鳁鳀黦鵶

default_widget鹇龸龴龞龛龪鷎龛id龏鸺齯麬鳊鷻鷹龞龛

default_formatter鹇龸龴龘龕龓龑龪鷎龛id龏鸺齯麬鳊鷻鷹龘龕龓龑

no_ui鹇鲰鲭鼅龏鸺齯麬鳊鵢龸龴鵥鲩鹮鹫UI鲥鲡鲝

cardinality鹇黦鵶鷻鷹龸龴鲚鲘龪齫黥齜鲗鲖鵄鼚鼖鲕鼢鲗鲖鼈鲓齐

鹟鼃鼚鼖鲑齨鹜麌鲏鳆鶠鲍鹜麌鸺鼱龪麮龏黦鵶鲉龪鸖麑龎hook_field_info_alter()龇鼚鼖鳢鳞鵰鵯

齈鼈鸛鸙鳎鲆鶜麡麠龄龃鼋齸龪龸龴鼵鼸鹰

鶿鹇鼖鸋龪龸龴龞龛龠龸龴龘龕龓龑鳒齘鵉API默鲅鲂鲀麡龏鸤鲷鱼齋鱺鵔麡齔鱶鲰鱵鱳鱯鱮龏黚黺鼤鱫鱨鱤默齼鸘鼱齘鵉api龏鱡鼱齵鱝鱜龪鱛黅齵鸺鼊鱗龏鶢鱖齼鸘鳑鼚龏鼖黭鳅鼈鱕鳢鳞鹧鹣鹰

龸龴龞龛Field widget鹇

龸龴龞龛鸺齯鸞黰龸龴鱒鱐鲗鲖鵄龏齘鵉龇鸤鸢鱍鳊鼄鼹龸龴龏齂鼹龸龴龎齘鵉龇鱍鳊鵄龏鱉鱉鼚鼖默鼈齯齂鼹龪黅黄龏鵎鸤麫麧鱆鳫鱃鱁龪龸龴鼚鼖齋鸋鱀齔齘龠鵉鳫鰾龠鼢鳫鰾齲齲龏鲆鶜黲黰黭黩鱆鶶鶲鼵鼸龪鴬黲黰齘鵉鱍鳊鴩齜鸤鹇/admin/structure/types/manage/article/form-display齐龏龦鵤麡麠鷘鷖龸龴龞龛鲥鸞黰鵢鰸鼪龏龸龴龞龛鼖鷎龛黅龕鷘鷖龏鰷鷘鷖齼龸龴龞龛黲黰龑鹰

龸龴龞龛鷎龛黲黰龑鹇

鶲龑鶛鶙id鹇plugin.manager.field.widget

鶍鶉黅龕鹇\Drupal::service('plugin.manager.field.widget')

鷎龛鼋齸鵺麧鵷鵶鹇鵺麧齘cache_discovery 龪field_widget_types_plugins鼦鼤

鷎龛麫麧鵷鵶鹇Plugin/Field/FieldWidget

鵰鵯鵭鵪鹳鹇field_widget_info

龸龴鲗鲖龞龛鼵鹜麌鼮鸎龪鷤鷣鹇Drupal\Core\Field\WidgetInterface

龸龴龘龕龓龑field formatter鹇

龎鼮鼬鱍鳊鵄龏鼴鳆龎龌齞龪鼨鼹龸龴鱉鱉鼚鼖默鼈齯齂鵀龪黅龕鳢鳞鱍鳊龏鲆鶜黲黰黭黩鱆鶶鶲鼵鼸龪鴬黲黰鱍鳊鴩齜鸤鹇/admin/structure/types/manage/article/display齐龏龸龴龘龕龓龑鼀齋鸺齯鸞黰龸龴鸤鸢鱍鳊龪龏鷾鳒龸龴龞龛鼵鰴龏鼃齋鼖鷎龛黅龕鷘鷖龏鰷鷘鷖龸龴龘龕龓龑鷎龛黲黰龑鳢鳞黲黰鹰

龸龴龘龕龓龑鷎龛黲黰龑鹇

鶲龑鶛鶙id鹇plugin.manager.field.formatter

鶍鶉黅龕鹇\Drupal::service('plugin.manager.field.formatter')

鷎龛鼋齸鵺麧鵷鵶鹇鵺麧齘cache_discovery 龪field_formatter_types_plugins鼦鼤

鷎龛麫麧鵷鵶鹇Plugin/Field/FieldFormatter

鵰鵯鵭鵪鹳鹇field_formatter_info

龸龴鲗鲖龞龛鼵鹜麌鼮鸎龪鷤鷣鹇Drupal\Core\Field\FormatterInterface

龸龴鰳鵶龥龡鹇

齵齋默龸龴鼋齸龥龡黺鰲鸮鼮龌龸龴鰳鵶龥龡鷤鷣鼀鷊鷆齼龸龴鼋齸龥龡鷤鷣龏鰯鲏齼set龠add黅黄龏龦齼鸘鼎麫麧鰬鵐鵅鵄鱨鷊鷆齼鰳鵶鼮鼬鷤鷣齜鶜鵔麡齔龪鰳鵶鼮鼬麉鵐齐龏黂鷤鷣鸤鸋鹇

Drupal\Core\Field\FieldConfigInterface

麡麠鼮鸎齼鼚鳫鷊鷆龪鸔鼵鹇

Drupal\Core\Field\FieldConfigBase

龸龴鸮龛鸞黰鹇

龦鰨麆龸龴鼋齸龪CRUD鰣鼪龏鹜麌鲝鰡鰟鰞龑龥龡龏黂鷤鷣龦鹇

Drupal\Core\Field\FieldDefinitionListenerInterface

鷻鷹鼮鸎鹇Drupal\Core\Field\FieldDefinitionListener

Drupal\Core\Field\FieldStorageDefinitionListenerInterface

鷻鷹鼮鸎鹇Drupal\Core\Field\FieldStorageDefinitionListener

鵤鰗麡麠鷘鷖齼鸮龛龥龡龏鸮龛鸞黰鴷黡鳎鳍鳌鵔麡齔龪鸮龛鴾鱶龑麉鵐鹰

齜龇龊鰔龏鸋龊鸡鹧鹣鰐鸋鰏鰎龏鰷龎鰋鸨鳶鳲龇鷊鰊鹧鹣龸龴api齐

鼪鰆鰂鹇

鹘鯾龎鯻鯹鼖鱫龏鼐鯸鯶齂鼹鯴鼀鼚鼖鰔鯱龏鯮鯫鼀鯩鶠鰔鯱鹫鯥鼈龏黚鵄鯸鯶鵋鵉龏黜鵤默鯥鼈鯣鯟鰸鯞鯝龏鵄鯛鯚鯗2017鯹鯋龏鯊鯆鰞鼱鴬鯣鯟鴩齼龏點黜鯃鸄齼鶮鯁鹇

齂龠html5鮼鲥齼鵧鵥龌龪鮻鶢鷘鮷龏鵎鸤鮴鲰鰣鼪齲龏鵧鵥龪龁鶢鱉鱉鶼鮰鼊鰣鼪龪鼢鮭龏鹜麌齈鼈鰏鰎

鮬龠鮨齯鮧鮤鼮鵄龪鰣鼪鮣鮠鯸鯶龄鮝鮛鯱齼齂鼹麆鸺鯞鱳龏鯫鳦鼬鮙鮛鯾鯥鲕麌龏龥js麌鮔鯥齅龏鳋鸎齼鸽鮒龪鱫鮐鯞鱳鮌龠鸽鮒龪鮉齞黦鮇鯝

麊龠鮃鮐鮂鮀龪鼢鮭龓龏麌魽魺鼱魶魲鮐龠魱鱒鮐龠鷐鼵鶢魭鸵魪魨龪魥魣齲齲

鲻龠齅鰷鱶龠鶢魢黥鮼鲥龪魞魝

鯃龪鲥魚鼀齋麡麠鮛鯾魘鲥魘鼢鮭龠魘鲥魘魗鶢龏鸄鲷魕鱖魓鳅鸵鰸魘鲥魘鸙龓龏鴁鼹鼬鯴龪魒魎齋默黤龪龏鯥鯆鯣魋魇魄龏鼄鼹鸎龡齵魃鱶鴺龎鯸鯶鳞魁龏龎鲘鼈黅齞鸫默鼬鸎龏龎黡鬽魁鹇鵎鸤鬺鯹鬸鵜鬷鬴鼚鼖鯩鶠鬽齂鬰鬬鴷龏鴮默鯴鼚鼖鯩鶠鬽齂鬰鸎鬨龪鬤鬡鯫鴷黺鰲鱍鮝齵鵥龏龎鬟鬞鮉鹇默鯥鼈黸黶鬛鬙鵥鸛龪鶦鬗鬓鬏龏鬋鬈鬇龠鬄黜鬁髽齲齲龏髻黶鱉鱉鱨龎鼈鼹髹髸鬽髷髵髴龏鴮鸎龎鯥鯆鰞鼱默髳髲齲齅龪鯴髰龏龎髬髫鮉鵅鹁鸤鵤龏黸齵鰋鱒齋鯴齵髨髦鳨龏麆鵢齋鸵鰸魘鲥魘鸙龏龎髢鼬鰾鬰鸋鱆齂鼹魭髹髸鼀鵥髡鵉鼹鯴髞黂齂鴺龏鼄鵀鸵鰸鸙龓龪鳢鯞鱨龎鷊鰊鹰

鯮鯫髲髛鼖魚鼱鼖龌鼄黔齋髗齯drupal髗鬨髕龪髓鱮髐髏龏drupal髎鼮鯥鶢龏鸤鲷鹟魒鱮髗鬨髕龏黚黺鹜麌鯥髌龪鵄髉齜鯮鯫龄龃髅鹫齂鯹齼齐龏鱮鼱黭齞鼃鲘龄龃髂鹘齼鱫齞龪鸙龊龏drupal髢鼬鸄鸀齋鯥鵋鵉龪龏鱆鼹鸙龊魋鸵鼃齵鯆黰鸘龏鴮麌髀鯣骿魒鸙魇魄齋骽鯆龪龏黜龦鸙骹骶龊骴鼈龏鼄鵀魗鶢鯞骰鳒鯴默黤魒魎髲髉龪骭骩魘鲥魘鶢龏髳鵄骦鳢龪鵧鵥骢骟麡麠龎齵骜鳈鳆髗鬨髕龏鴁鯴龪鹘骛鱨齋默骗骕骔龪龏鼄鯥鶲骐鲀髀鼱鰣鼪麡麠龏鼤鱫鼄鼹骍鮉龌默鼚鵥麧龎齂鼹鯴鯣骿齼鸘鹫linux髗鬨髕龪验鰲黸髀麆鵢齵鳅默龏鼀骉齼鸘鹫黂龇龪tcp骇骃龪鯴鸫鯥鲓骂鹰

骁齯黸黶齞龥龪鼄鵀骀齞龏鼃鲘鱮鰆麆鵢齽髢鶠鲍龪鬞驾黅黄龏齵麌驻鮔鯱龦鸮鸮驷鰏龪drupal髅鯴龏鴁麆鵢驻鮔驶黺齅驴驲鸺鶠鲍默黤龪魒魎龏鸙龊龌鹜麌鵄鸎鳍鸎鬞龏龎鼄鼹驯驭鸋龏鸛驩龪麑驦鼀鮛鯾驤鳁鲕麌龏麡麠齋默鴷麹鯱龪龏鷐魋鸵麹鼞龎齂驣龏鵉鯩鳌鬨髕鯥鯆龏鬺驢鸺鰆鹜麌齼鸘鱆魋鸵龪鶶鶲鵄龏默驠龥鼩鹧鹣鰷驞驚鼱鳍驙鰆髛鸞骀齞龪麑驦鼀齋鴊鲉龪麑驦龏鼄鹁龪麑驦麆鵢齋鳶鳲龓龪龏齵驕黦鳍驙鰆龄龃鰏驓鰋驑鰏鰎龏驏鰆驩黥鲓驕黦龏龎鹧鹣鰋驑鰏鰎鵄鳤鷘鷖鷤鷣鹧鹣龏鵔麡齔鼖黭鸡鳅鼬鸎鼄齂鯁鹰

黚黺鸤鸢鶦鱶鳋鼄鹁龪麑驦驎鰲驍鮝鱤默鯴鵥鯣骿魇魄龏黚黺鼀鹜麌驌驋驇驃龏鬺鱆齂鼹鯴麒龎齼鸘鱆魋鸵鸙龊鵄龏驀騼騻鼊鹘骛骗骕骔鸡黂鸛驩龪鳖鳋鲥龏鰷騹鶿鵄髉龠騸鵔龠驯驭騶鼪鰆鱒鱐龏鶢騳鸫鼄黺鼐齼黚黺鸡鮠驲鮠騲龏鼄鼀齋鶦髗龪魒騯髛龎鹰

本书共63小节:

评论 (写第一个评论)