Commit 6efe0535 authored by nicola85's avatar nicola85

Improve code style

parent 34deae8c
This diff is collapsed.
<?php
/**
* @file
*/
/**
* Implements hook_default_services_endpoint().
......
<?php
/**
* @file
*/
/**
*
*/
interface BatTypeFieldHandlerInterface {
/**
* @return string
*/
public function getFieldType();
/**
* @return array
*/
public function getFieldInfo();
}
/**
*
*/
abstract class BatTypeFieldHandlerBase implements BatTypeFieldHandlerInterface {
/**
*
*/
protected $type;
/**
* @param BatType $type
*/
public function __construct(BatType $type) {
$this->type = $type;
}
}
<?php
/**
* @file
*/
/**
*
*/
interface BatUnitFieldHandlerInterface {
/**
* @return string
*/
public function getFieldType();
/**
* @return array
*/
public function getFieldInfo();
}
/**
*
*/
abstract class BatUnitFieldHandlerBase implements BatUnitFieldHandlerInterface {
/**
*
*/
protected $unit;
/**
* @param BatUnit $unit
*/
public function __construct(BatUnit $unit) {
$this->unit = $unit;
}
}
<?php
/**
* @file
*/
$plugin = array(
'label' => t('Commerce Price'),
......@@ -8,11 +11,21 @@ $plugin = array(
),
);
/**
*
*/
class BatTypeFieldHandlerCommercePrice extends BatTypeFieldHandlerBase {
/**
* {@inheritdoc}
*/
public function getFieldType() {
return 'commerce_price';
}
/**
* {@inheritdoc}
*/
public function getFieldInfo() {
$price_fields = array();
......@@ -36,4 +49,5 @@ class BatTypeFieldHandlerCommercePrice extends BatTypeFieldHandlerBase {
return $price_fields;
}
}
<?php
/**
* @file
*/
$plugin = array(
'label' => t('Commerce Price'),
......@@ -8,11 +11,21 @@ $plugin = array(
),
);
/**
*
*/
class BatUnitFieldHandlerCommercePrice extends BatUnitFieldHandlerBase {
/**
* {@inheritdoc}
*/
public function getFieldType() {
return 'commerce_price';
}
/**
* {@inheritdoc}
*/
public function getFieldInfo() {
$price_fields = array();
......@@ -34,4 +47,5 @@ class BatUnitFieldHandlerCommercePrice extends BatUnitFieldHandlerBase {
return $price_fields;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment