PHP Interface Mlp_Translatable_Post_Data_Interface

Used by the view.
Author: Inpsyde GmbH, toscho, tf
Afficher le fichier Open project: inpsyde/multilingual-press Interface Usage Examples

Méthodes publiques

Méthode Description
find_post_parents ( string $post_type, integer $post_parent ) : void
get_dummy_post ( string $post_type ) : WP_Post
get_post_meta_to_transfer ( ) : array
get_post_parent ( $blog_id ) : integer
get_real_post_id ( integer $post_id ) : integer Figure out the post ID.
get_real_post_type ( WP_Post $post ) : string
get_remote_language ( integer $blog_id ) : string
get_remote_post ( WP_Post $source_post, integer $blog_id ) : WP_Post
set_linked_element ( integer $source_content_id, integer $remote_site_id, integer $remote_content_id ) : void set the source id of the element
set_save_context ( array $save_context = [] ) : void Set the context of the to-be-saved post.
update_remote_post_meta ( integer $remote_post_id, array $post_meta = [] ) : void Add source post meta to remote post.

Method Details

find_post_parents() public méthode

public find_post_parents ( string $post_type, integer $post_parent ) : void
$post_type string
$post_parent integer
Résultat void

get_dummy_post() public méthode

public get_dummy_post ( string $post_type ) : WP_Post
$post_type string
Résultat WP_Post

get_post_meta_to_transfer() public méthode

public get_post_meta_to_transfer ( ) : array
Résultat array

get_post_parent() public méthode

public get_post_parent ( $blog_id ) : integer
$blog_id
Résultat integer

get_real_post_id() public méthode

Inspects POST request data and too, because we get two IDs on auto-drafts.
public get_real_post_id ( integer $post_id ) : integer
$post_id integer
Résultat integer

get_real_post_type() public méthode

public get_real_post_type ( WP_Post $post ) : string
$post WP_Post
Résultat string

get_remote_language() public méthode

public get_remote_language ( integer $blog_id ) : string
$blog_id integer
Résultat string

get_remote_post() public méthode

public get_remote_post ( WP_Post $source_post, integer $blog_id ) : WP_Post
$source_post WP_Post
$blog_id integer
Résultat WP_Post

set_linked_element() public méthode

set the source id of the element
public set_linked_element ( integer $source_content_id, integer $remote_site_id, integer $remote_content_id ) : void
$source_content_id integer ID of current element
$remote_site_id integer ID of remote site
$remote_content_id integer ID of remote content
Résultat void

set_save_context() public méthode

Set the context of the to-be-saved post.
public set_save_context ( array $save_context = [] ) : void
$save_context array Save context.
Résultat void

update_remote_post_meta() public méthode

Add source post meta to remote post.
public update_remote_post_meta ( integer $remote_post_id, array $post_meta = [] ) : void
$remote_post_id integer
$post_meta array
Résultat void