Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
02/03/2016 05:01:13 AM (9 years ago)
Author:
tw2113
Message:

Adds many missing @since tags to the BP Core component.

See #6398.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-functions.php

    r10491 r10497  
    8383 *
    8484 * The filter is intended primarily for use in multinetwork installations.
     85 *
     86 * @since 1.2.6
    8587 *
    8688 * @global object $wpdb WordPress database object.
     
    171173 * Format numbers the BuddyPress way.
    172174 *
     175 * @since 1.2.0
     176 *
    173177 * @param int  $number   The number to be formatted.
    174178 * @param bool $decimals Whether to use decimals. See {@link number_format_i18n()}.
     
    251255 * are applied.
    252256 *
    253  * @since r7704
     257 * @since 2.0.0
    254258 *
    255259 * @param string|array $args       Value to merge with $defaults.
     
    777781 * with the new method.
    778782 *
     783 * @since 1.0.0
     784 *
    779785 * @param string $slug The slug of the component being added to the root list.
    780786 */
     
    816822/**
    817823 * Create WordPress pages to be used as BP component directories.
     824 *
     825 * @since 1.5.0
    818826 */
    819827function bp_core_create_root_component_page() {
     
    842850 *
    843851 * For example, it would stop someone creating a blog with the slug "groups".
     852 *
     853 * @since 1.0.0
    844854 *
    845855 * @todo Deprecate?
     
    918928 * Eg: http://example.com OR https://example.com
    919929 *
     930 * @since 1.0.0
     931 *
    920932 * @uses get_blog_option() WordPress function to fetch blog meta.
    921933 *
     
    938950/**
    939951 * Perform a status-safe wp_redirect() that is compatible with BP's URI parser.
     952 *
     953 * @since 1.0.0
    940954 *
    941955 * @uses wp_safe_redirect()
     
    9881002/**
    9891003 * Get the path of the current site.
     1004 *
     1005 * @since 1.0.0
    9901006 *
    9911007 * @global object $current_site
     
    10651081 * an interval of 3 minutes will be represented by "3 minutes ago", as will an
    10661082 * interval of 3 minutes 59 seconds.
     1083 *
     1084 * @since 1.0.0
    10671085 *
    10681086 * @uses apply_filters() Filter 'bp_core_time_since_pre' to bypass BP's calculations.
     
    12651283 * Add a feedback (error/success) message to the WP cookie so it can be displayed after the page reloads.
    12661284 *
     1285 * @since 1.0.0
     1286 *
    12671287 * @param string $message Feedback message to be displayed.
    12681288 * @param string $type    Message type. 'updated', 'success', 'error', 'warning'.
     
    13011321 * so that the message is not shown to the user multiple times.
    13021322 *
     1323 * @since 1.1.0
     1324 *
    13031325 * @uses setcookie() Sets a cookie value for the user.
    13041326 */
     
    13331355 * The hook action 'template_notices' is used to call this function, it is not
    13341356 * called directly.
     1357 *
     1358 * @since 1.1.0
    13351359 */
    13361360function bp_core_render_message() {
     
    13811405 * site.
    13821406 *
     1407 * @since 1.0.0
     1408 *
    13831409 * @uses bp_update_user_meta() BP function to update user metadata in the
    13841410 *       usermeta table.
     
    14371463 * Format last activity string based on time since date given.
    14381464 *
     1465 * @since 1.0.0
     1466 *
    14391467 * @uses bp_core_time_since() This function will return an English
    14401468 *       representation of the time elapsed.
     
    17571785 *     add_action( bp_core_admin_hook(), 'myplugin_dashboard_panel_setup' );
    17581786 *
     1787 * @since 1.5.0
     1788 *
    17591789 * @return string $hook The proper hook ('network_admin_menu' or 'admin_menu').
    17601790 */
     
    19281958 * Set the "is_directory" global.
    19291959 *
     1960 * @since 1.5.0
     1961 *
    19301962 * @param bool   $is_directory Optional. Default: false.
    19311963 * @param string $component    Optional. Component name. Default: the current
     
    19521984 * Set the "is_item_admin" global.
    19531985 *
     1986 * @since 1.5.0
     1987 *
    19541988 * @param bool   $is_item_admin Optional. Default: false.
    19551989 * @param string $component     Optional. Component name. Default: the current
     
    19752009/**
    19762010 * Set the "is_item_mod" global.
     2011 *
     2012 * @since 1.5.0
    19772013 *
    19782014 * @param bool   $is_item_mod Optional. Default: false.
     
    21392175 * Load the buddypress translation file for current language.
    21402176 *
     2177 * @since 1.0.2
     2178 *
    21412179 * @see load_textdomain() for a description of return values.
    21422180 *
     
    21812219/**
    21822220 * A JavaScript-free implementation of the search functions in BuddyPress.
     2221 *
     2222 * @since 1.0.1
    21832223 *
    21842224 * @param string $slug The slug to redirect to for searching.
     
    22552295/**
    22562296 * Print the generation time in the footer of the site.
     2297 *
     2298 * @since 1.0.0
    22572299 */
    22582300function bp_core_print_generation_time() {
     
    26182660         * @since 2.5.0
    26192661         *
    2620          * @param string $post_type Email post type name.
     2662         * @param string $value Email post type name.
    26212663         */
    26222664        return apply_filters( 'bp_get_email_post_type', buddypress()->email_post_type );
     
    26372679     * @since 2.5.0
    26382680     *
    2639      * @param string[] $labels Associative array (name => label).
     2681     * @param array $value Associative array (name => label).
    26402682     */
    26412683    return apply_filters( 'bp_get_email_post_type_labels', array(
     
    26722714     * @since 2.5.0
    26732715     *
    2674      * @param string[] $features Supported features.
     2716     * @param array $value Supported features.
    26752717     */
    26762718    return apply_filters( 'bp_get_email_post_type_supports', array(
     
    27082750         * @since 2.5.0
    27092751         *
    2710          * @param string $taxonomy Email type taxonomy name.
     2752         * @param string $value Email type taxonomy name.
    27112753         */
    27122754        return apply_filters( 'bp_get_email_tax_type', buddypress()->email_taxonomy_type );
     
    27182760 * @since 2.5.0
    27192761 *
    2720  * @return string[]
     2762 * @return array
    27212763 */
    27222764function bp_get_email_tax_type_labels() {
     
    27272769     * @since 2.5.0
    27282770     *
    2729      * @param string[] $labels Associative array (name => label).
     2771     * @param array $value Associative array (name => label).
    27302772     */
    27312773    return apply_filters( 'bp_get_email_tax_type_labels', array(
     
    28132855     * @param string  $email_type Unique identifier for a particular type of email.
    28142856     * @param array   $args       Arguments used with get_posts() to fetch a post object.
    2815      * @param WP_Post[] All posts retrieved by get_posts( $args ). May only contain $post.
     2857     * @param WP_Post $post      All posts retrieved by get_posts( $args ). May only contain $post.
    28162858     */
    28172859    $post  = apply_filters( 'bp_get_email_post', $post[0], $email_type, $args, $post );
     
    28322874     *
    28332875     * @param BP_Email $email      An object representing a single email, ready for mailing.
    2834      * @param WP_Post  $post       Post object containing the contents of the email.
    28352876     * @param string   $email_type Unique identifier for a particular type of email.
    28362877     * @param array    $args       Arguments used with get_posts() to fetch a post object.
    2837      * @param WP_Post[] All posts retrieved by get_posts( $args ). May only contain $post.
     2878     * @param WP_Post  $post      All posts retrieved by get_posts( $args ). May only contain $post.
    28382879     */
    28392880    $retval = apply_filters( 'bp_get_email', $email, $email_type, $args, $post );
     
    28552896 * @since 2.5.0
    28562897 *
    2857  * @param string $email_type Type of email being sent.
    2858  * @param string|array|int|WP_User $to Either a email address, user ID, WP_User object,
    2859  *                                     or an array containing any combination of the above.
    2860  * @param array $args {
     2898 * @param string                   $email_type Type of email being sent.
     2899 * @param string|array|int|WP_User $to         Either a email address, user ID, WP_User object,
     2900 *                                             or an array containg the address and name.
     2901 * @param array                    $args {
    28612902 *     Optional. Array of extra. parameters.
    28622903 *
     
    28772918    }
    28782919
    2879     // wp_mail() is a pluggable function. Has it been re-defined by another plugin?
     2920    // Since wp_mail() is a pluggable function, has it been re-defined by another plugin?
    28802921    if ( is_null( $is_default_wpmail ) ) {
    28812922        try {
     
    29442985     * @since 2.5.0
    29452986     *
    2946      * @param string $deliver_class The email delivery class name.
    2947      * @param string $email_type Type of email being sent.
    2948      * @param string[]|string $to Array or comma-separated list of email addresses to the email to.
    2949      * @param array $args {
     2987     * @param string       $deliver_class The email delivery class name.
     2988     * @param string       $email_type    Type of email being sent.
     2989     * @param array|string $to            Array or comma-separated list of email addresses to the email to.
     2990     * @param array        $args {
    29502991     *     Optional. Array of extra parameters.
    29512992     *
     
    29623003
    29633004    if ( is_wp_error( $status ) ) {
     3005
    29643006        /**
    29653007         * Fires after BuddyPress has tried - and failed - to send an email.
     
    29693011         * @param WP_Error $status A WP_Error object describing why the email failed to send. The contents
    29703012         *                         will vary based on the email delivery class you are using.
    2971          * @param BP_Email $email The email we tried to send.
     3013         * @param BP_Email $email  The email we tried to send.
    29723014         */
    29733015        do_action( 'bp_send_email_failure', $status, $email );
    29743016
    29753017    } else {
     3018
    29763019        /**
    29773020         * Fires after BuddyPress has succesfully sent an email.
     
    29793022         * @since 2.5.0
    29803023         *
    2981          * @param bool $status True if the email was sent successfully.
    2982          * @param BP_Email $email The email sent.
     3024         * @param bool     $status True if the email was sent successfully.
     3025         * @param BP_Email $email  The email sent.
    29833026         */
    29843027        do_action( 'bp_send_email_success', $status, $email );
     
    30303073 *
    30313074 * @param WP_Post $object Post to get email template for.
    3032  * @return string[]
     3075 * @return array
    30333076 */
    30343077function bp_email_get_template( WP_Post $object ) {
     
    30403083     * @since 2.5.0
    30413084     *
    3042      * @param string[] $templates
     3085     * @param array   $value  Array of possible template paths.
     3086     * @param WP_Post $object WP_Post object.
    30433087     */
    30443088    return apply_filters( 'bp_email_get_template', array(
Note: See TracChangeset for help on using the changeset viewer.