Completed
Push — add/amp-pwa-experiment ( efea12 )
by
unknown
11:53
created

AMP_Base_Embed_Handler   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
dl 0
loc 21
rs 10
c 0
b 0
f 0
wmc 2
lcom 0
cbo 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
register_embed() 0 1 ?
unregister_embed() 0 1 ?
A __construct() 0 6 1
A get_scripts() 0 3 1
1
<?php
2
3
// Used by some children
4
require_once( AMP__ROOT__ . '/includes/utils/class-amp-html-utils.php' );
5
6
abstract class AMP_Base_Embed_Handler {
7
	protected $DEFAULT_WIDTH = 600;
8
	protected $DEFAULT_HEIGHT = 480;
9
10
	protected $args = array();
11
	protected $did_convert_elements = false;
12
13
	abstract function register_embed();
14
	abstract function unregister_embed();
15
16
	function __construct( $args = array() ) {
17
		$this->args = wp_parse_args( $args, array(
18
			'width' => $this->DEFAULT_WIDTH,
19
			'height' => $this->DEFAULT_HEIGHT,
20
		) );
21
	}
22
23
	public function get_scripts() {
24
		return array();
25
	}
26
}
27