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

Field::make()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 3
rs 10
cc 1
eloc 2
nc 1
nop 3
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