Completed
Push — master ( 6a57b0...e13082 )
by Marin
02:25
created

Field   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 2
c 1
b 0
f 1
lcom 0
cbo 1
dl 0
loc 19
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A factory() 0 3 1
A make() 0 3 1
1
<?php 
2
3
namespace Carbon_Fields;
4
5
use Carbon_Fields\Field\Field as Abstract_Field;
6
7
/**
8
 * Field proxy factory class.
9
 * Used for shorter namespace access when creating a field.
10
 **/
11
class Field {
12
	/**
13
	 * A proxy for the abstract field factory method.
14
	 *
15
	 * @see Carbon_Fields\Field\Field::factory()
16
	 **/
17
	public static function factory( $type, $name, $label = null ) {
18
		return Abstract_Field::factory( $type, $name, $label );
19
	}
20
21
	/**
22
	 * An alias of factory().
23
	 *
24
	 * @see Field::factory()
25
	 **/
26
	public static function make( $type, $name, $label = null ) {
27
		return self::factory( $type, $name, $label );
28
	}
29
}
30