class-wpml-translationproxy-com-log.php
1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<?php
class WPML_TranslationProxy_Com_Log {
private static $wrapped_class;
/**
* @return WPML_TranslationProxy_Communication_Log
*/
private static function get_wrapped_class_instance() {
if ( null === self::$wrapped_class ) {
global $sitepress;
self::$wrapped_class = new WPML_TranslationProxy_Communication_Log( $sitepress );
}
return self::$wrapped_class;
}
public static function log_call( $url, $params ) {
self::get_wrapped_class_instance()->log_call( $url, $params );
}
public static function get_keys_to_block() {
return self::get_wrapped_class_instance()->get_keys_to_block();
}
public static function log_response( $response ) {
self::get_wrapped_class_instance()->log_response( $response );
}
public static function log_error( $message ) {
self::get_wrapped_class_instance()->log_error( $message );
}
public static function log_xml_rpc( $data ) {
self::get_wrapped_class_instance()->log_xml_rpc( $data );
}
public static function get_log() {
return self::get_wrapped_class_instance()->get_log();
}
public static function clear_log() {
self::get_wrapped_class_instance()->clear_log();
}
public static function is_logging_enabled() {
return self::get_wrapped_class_instance()->is_logging_enabled();
}
/**
* @param string|array|stdClass $params
*
* @return array|stdClass
*/
public static function sanitize_data( $params ) {
return self::get_wrapped_class_instance()->sanitize_data( $params );
}
/**
* @param $url
*
* @return mixed
*/
public static function sanitize_url( $url ) {
return self::get_wrapped_class_instance()->sanitize_url( $url );
}
public static function set_logging_state( $state ) {
self::get_wrapped_class_instance()->set_logging_state( $state );
}
public static function add_com_log_link() {
self::get_wrapped_class_instance()->add_com_log_link();
}
}