ILIAS  release_7 Revision v7.30-3-g800a261c036
ilSystemStyleLessVariable Class Reference
+ Inheritance diagram for ilSystemStyleLessVariable:
+ Collaboration diagram for ilSystemStyleLessVariable:

Public Member Functions

 __construct ($name, $value, $comment, $category_name, $references)
 ilSystemStyleLessVariable constructor. More...
 
 getName ()
 
 setName ($name)
 
 getValue ()
 
 setValue ($value)
 
 getComment ()
 
 setComment ($comment)
 
 getCategoryName ()
 
 setCategoryName ($category_name)
 
 getReferences ()
 
 setReferences ($references)
 
 __toString ()
 This function will be needed to write the variable back to the less file and restore it's initial structure in less. More...
 
 __toString ()
 

Protected Attributes

 $name = ""
 
 $value = ""
 
 $comment = ""
 
 $category_name = ""
 
 $references = array()
 

Detailed Description

Definition at line 15 of file class.ilSystemStyleLessVariable.php.

Constructor & Destructor Documentation

◆ __construct()

ilSystemStyleLessVariable::__construct (   $name,
  $value,
  $comment,
  $category_name,
  $references 
)

ilSystemStyleLessVariable constructor.

Parameters
$name
$value
$comment
$category_name
$references

Definition at line 60 of file class.ilSystemStyleLessVariable.php.

References $category_name, $comment, $name, $references, $value, setCategoryName(), setComment(), setName(), setReferences(), and setValue().

+ Here is the call graph for this function:

Member Function Documentation

◆ __toString()

ilSystemStyleLessVariable::__toString ( )

This function will be needed to write the variable back to the less file and restore it's initial structure in less.

Returns
string

Reimplemented from ilSystemStyleLessItem.

Definition at line 172 of file class.ilSystemStyleLessVariable.php.

173 {
174 $content = "";
175 if ($this->getComment()) {
176 $content .= "//** " . $this->getComment() . "\n";
177 }
178 $content .= "@" . $this->getName() . ":\t\t" . $this->getValue() . ";\n";
179 return $content;
180 }

References getComment(), getName(), and getValue().

+ Here is the call graph for this function:

◆ getCategoryName()

ilSystemStyleLessVariable::getCategoryName ( )
Returns
string

Definition at line 136 of file class.ilSystemStyleLessVariable.php.

137 {
139 }

References $category_name.

◆ getComment()

ilSystemStyleLessVariable::getComment ( )
Returns
string

Definition at line 119 of file class.ilSystemStyleLessVariable.php.

120 {
121 return $this->comment;
122 }

References $comment.

Referenced by __toString().

+ Here is the caller graph for this function:

◆ getName()

ilSystemStyleLessVariable::getName ( )
Returns
string

Definition at line 72 of file class.ilSystemStyleLessVariable.php.

73 {
74 return $this->name;
75 }

References $name.

Referenced by __toString(), and setValue().

+ Here is the caller graph for this function:

◆ getReferences()

ilSystemStyleLessVariable::getReferences ( )
Returns
array

Definition at line 152 of file class.ilSystemStyleLessVariable.php.

153 {
154 return $this->references;
155 }

References $references.

◆ getValue()

ilSystemStyleLessVariable::getValue ( )
Returns
string

Definition at line 88 of file class.ilSystemStyleLessVariable.php.

89 {
90 return $this->value;
91 }

References $value.

Referenced by __toString().

+ Here is the caller graph for this function:

◆ setCategoryName()

ilSystemStyleLessVariable::setCategoryName (   $category_name)
Parameters
string$category_name

Definition at line 144 of file class.ilSystemStyleLessVariable.php.

145 {
146 $this->category_name = $category_name;
147 }

References $category_name.

Referenced by __construct().

+ Here is the caller graph for this function:

◆ setComment()

ilSystemStyleLessVariable::setComment (   $comment)
Parameters
string$comment

Definition at line 127 of file class.ilSystemStyleLessVariable.php.

128 {
129 $comment = str_replace(PHP_EOL, '', $comment);
130 $this->comment = str_replace("\n", '', $comment);
131 }
comment()
Definition: comment.php:2

References $comment, and comment().

Referenced by __construct().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setName()

ilSystemStyleLessVariable::setName (   $name)
Parameters
string$name

Definition at line 80 of file class.ilSystemStyleLessVariable.php.

81 {
82 $this->name = $name;
83 }

References $name.

Referenced by __construct().

+ Here is the caller graph for this function:

◆ setReferences()

ilSystemStyleLessVariable::setReferences (   $references)
Parameters
array$references

Definition at line 160 of file class.ilSystemStyleLessVariable.php.

161 {
162 $this->references = $references;
163 }

References $references.

Referenced by __construct().

+ Here is the caller graph for this function:

◆ setValue()

ilSystemStyleLessVariable::setValue (   $value)
Parameters
string$value

Definition at line 96 of file class.ilSystemStyleLessVariable.php.

97 {
98 if ($this->getName() == "il-icon-font-path" ) {
99 if ($value[0] != "\"") {
100 $value = "\"" . $value;
101 ;
102 }
103 if (substr($value, -1, 1) != "\"") {
104 $value .= "\"";
105 }
106
107 if ($value == "\"../../node_modules/bootstrap/fonts/\"") {
108 $value = "\"../../../../node_modules/bootstrap/fonts/\"";
109 }
110 }
111
112 $value = str_replace(PHP_EOL, '', $value);
113 $this->value = str_replace("\n", '', $value);
114 }

References $value, and getName().

Referenced by __construct().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $category_name

ilSystemStyleLessVariable::$category_name = ""
protected

◆ $comment

ilSystemStyleLessVariable::$comment = ""
protected

Definition at line 37 of file class.ilSystemStyleLessVariable.php.

Referenced by __construct(), getComment(), and setComment().

◆ $name

ilSystemStyleLessVariable::$name = ""
protected

Definition at line 23 of file class.ilSystemStyleLessVariable.php.

Referenced by __construct(), getName(), and setName().

◆ $references

ilSystemStyleLessVariable::$references = array()
protected

Definition at line 50 of file class.ilSystemStyleLessVariable.php.

Referenced by __construct(), getReferences(), and setReferences().

◆ $value

ilSystemStyleLessVariable::$value = ""
protected

Definition at line 30 of file class.ilSystemStyleLessVariable.php.

Referenced by __construct(), getValue(), and setValue().


The documentation for this class was generated from the following file: