Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
09/25/2015 02:19:11 AM (11 years ago)
Author:
tw2113
Message:

Finishing off the XProfile class files for @since changes.

See #6576.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-field-type.php

    r9819 r10142  
    1313 * Represents a type of XProfile field and holds meta information about the type of value that it accepts.
    1414 *
    15  * @since BuddyPress (2.0.0)
     15 * @since 2.0.0
    1616 */
    1717abstract class BP_XProfile_Field_Type {
    1818
    1919        /**
    20          * @since BuddyPress (2.0.0)
     20         * @since 2.0.0
    2121         * @var array Field type validation regexes
    2222         */
     
    2424
    2525        /**
    26          * @since BuddyPress (2.0.0)
     26         * @since 2.0.0
    2727         * @var array Field type whitelisted values
    2828         */
     
    3030
    3131        /**
    32          * @since BuddyPress (2.0.0)
     32         * @since 2.0.0
    3333         * @var string The name of this field type
    3434         */
     
    3838         * The name of the category that this field type should be grouped with. Used on the [Users > Profile Fields] screen in wp-admin.
    3939         *
    40          * @since BuddyPress (2.0.0)
     40         * @since 2.0.0
    4141         * @var string
    4242         */
     
    4444
    4545        /**
    46          * @since BuddyPress (2.0.0)
     46         * @since 2.0.0
    4747         * @var bool If this is set, allow BP to store null/empty values for this field type.
    4848         */
     
    5252         * If this is set, BP will set this field type's validation whitelist from the field's options (e.g checkbox, selectbox).
    5353         *
    54          * @since BuddyPress (2.0.0)
     54         * @since 2.0.0
    5555         * @var bool Does this field support options? e.g. selectbox, radio buttons, etc.
    5656         */
     
    5858
    5959        /**
    60          * @since BuddyPress (2.0.0)
     60         * @since 2.0.0
    6161         * @var bool Does this field type support multiple options being set as default values? e.g. multiselectbox, checkbox.
    6262         */
     
    6464
    6565        /**
    66          * @since BuddyPress (2.0.0)
     66         * @since 2.0.0
    6767         * @var BP_XProfile_Field If this object is created by instantiating a {@link BP_XProfile_Field}, this is a reference back to that object.
    6868         */
     
    7272         * Constructor
    7373         *
    74          * @since BuddyPress (2.0.0)
     74         * @since 2.0.0
    7575         */
    7676        public function __construct() {
     
    7979                 * Fires inside __construct() method for BP_XProfile_Field_Type class.
    8080                 *
    81                  * @since BuddyPress (2.0.0)
     81                 * @since 2.0.0
    8282                 *
    8383                 * @param BP_XProfile_Field_Type $this Current instance of
     
    9696         * @param string $replace_format Optional; if 'replace', replaces the format instead of adding to it. Defaults to 'add'.
    9797         * @return BP_XProfile_Field_Type
    98          * @since BuddyPress (2.0.0)
     98         * @since 2.0.0
    9999         */
    100100        public function set_format( $format, $replace_format = 'add' ) {
     
    103103                 * Filters the regex format for the field type.
    104104                 *
    105                  * @since BuddyPress (2.0.0)
     105                 * @since 2.0.0
    106106                 *
    107107                 * @param string                 $format         Regex string.
     
    129129         * @param string|array $values
    130130         * @return BP_XProfile_Field_Type
    131          * @since BuddyPress (2.0.0)
     131         * @since 2.0.0
    132132         */
    133133        public function set_whitelist_values( $values ) {
     
    137137                         * Filters values for field type's whitelist that profile data will be asserted against.
    138138                         *
    139                          * @since BuddyPress (2.0.0)
     139                         * @since 2.0.0
    140140                         *
    141141                         * @param string                 $value  Field value.
     
    156156         * @param string|array $values Value to check against the registered formats
    157157         * @return bool True if the value validates
    158          * @since BuddyPress (2.0.0)
     158         * @since 2.0.0
    159159         */
    160160        public function is_valid( $values ) {
     
    191191                 * Filters whether or not field type is a valid format.
    192192                 *
    193                  * @since BuddyPress (2.0.0)
     193                 * @since 2.0.0
    194194                 *
    195195                 * @param bool                   $validated Whether or not the field type is valid.
     
    206206         *
    207207         * @param array $raw_properties Optional key/value array of permitted attributes that you want to add.
    208          * @since BuddyPress (2.0.0)
     208         * @since 2.0.0
    209209         */
    210210        abstract public function edit_field_html( array $raw_properties = array() );
     
    223223         *
    224224         * @param array $args Optional. The arguments passed to {@link bp_the_profile_field_options()}.
    225          * @since BuddyPress (2.0.0)
     225         * @since 2.0.0
    226226         */
    227227        public function edit_field_options_html( array $args = array() ) {}
     
    233233         *
    234234         * @param array $raw_properties Optional key/value array of permitted attributes that you want to add.
    235          * @since BuddyPress (2.0.0)
     235         * @since 2.0.0
    236236         */
    237237        abstract public function admin_field_html( array $raw_properties = array() );
     
    248248         * @param BP_XProfile_Field $current_field The current profile field on the add/edit screen.
    249249         * @param string $control_type Optional. HTML input type used to render the current field's child options.
    250          * @since BuddyPress (2.0.0)
     250         * @since 2.0.0
    251251         */
    252252        public function admin_new_field_html( BP_XProfile_Field $current_field, $control_type = '' ) {
     
    357357                                 * Fires at the end of the new field additional settings area.
    358358                                 *
    359                                  * @since BuddyPress (2.3.0)
     359                                 * @since 2.3.0
    360360                                 *
    361361                                 * @param BP_XProfile_Field $current_field Current field being rendered.
     
    383383         * validation filtering.
    384384         *
    385          * @since BuddyPress (2.1.0)
     385         * @since 2.1.0
    386386         *
    387387         * @param mixed $submitted_value Submitted value.
     
    399399         * filtering for output values.
    400400         *
    401          * @since BuddyPress (2.1.0)
     401         * @since 2.1.0
    402402         *
    403403         * @param mixed $field_value Field value.
     
    418418         * @param array $properties Optional key/value array of attributes for this edit field.
    419419         * @return string
    420          * @since BuddyPress (2.0.0)
     420         * @since 2.0.0
    421421         */
    422422        protected function get_edit_field_html_elements( array $properties = array() ) {
     
    436436                 * Filters the edit html elements and attributes.
    437437                 *
    438                  * @since BuddyPress (2.0.0)
     438                 * @since 2.0.0
    439439                 *
    440440                 * @param array  $r     Array of parsed arguments.
Note: See TracChangeset for help on using the changeset viewer.