PluginProbe
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress / 10.1.4
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress v10.1.4
11.1.1 11.1.0 11.0.5 11.0.4 11.0.3 11.0.2 11.0.1 11.0.0 10.11.1 10.11.0 10.10.2 10.10.1 10.10.0 10.9.1 trunk 10.0.0 10.0.1 10.1.0 10.1.1 10.1.2 10.1.3 10.1.4 10.2.0 10.2.1 10.2.2 All 62 releases
acymailing / back / Libraries / Sabberworm / CSS / src / Value / CSSFunction.php

CSSFunction.php in AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress 10.1.4, at back/Libraries/Sabberworm/CSS/src/Value/CSSFunction.php

74 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace Sabberworm\CSS\Value;
4
5 use Sabberworm\CSS\OutputFormat;
6
7 class CSSFunction extends ValueList
8 {
9 /**
10 * @var string
11 */
12 protected $sName;
13
14 /**
15 * @param string $sName
16 * @param RuleValueList|array<int, RuleValueList|CSSFunction|CSSString|LineName|Size|URL|string> $aArguments
17 * @param string $sSeparator
18 * @param int $iLineNo
19 */
20 public function __construct($sName, $aArguments, $sSeparator = ',', $iLineNo = 0)
21 {
22 if ($aArguments instanceof RuleValueList) {
23 $sSeparator = $aArguments->getListSeparator();
24 $aArguments = $aArguments->getListComponents();
25 }
26 $this->sName = $sName;
27 $this->iLineNo = $iLineNo;
28 parent::__construct($aArguments, $sSeparator, $iLineNo);
29 }
30
31 /**
32 * @return string
33 */
34 public function getName()
35 {
36 return $this->sName;
37 }
38
39 /**
40 * @param string $sName
41 *
42 * @return void
43 */
44 public function setName($sName)
45 {
46 $this->sName = $sName;
47 }
48
49 /**
50 * @return array<int, RuleValueList|CSSFunction|CSSString|LineName|Size|URL|string>
51 */
52 public function getArguments()
53 {
54 return $this->aComponents;
55 }
56
57 /**
58 * @return string
59 */
60 public function __toString()
61 {
62 return $this->render(new OutputFormat());
63 }
64
65 /**
66 * @return string
67 */
68 public function render(OutputFormat $oOutputFormat)
69 {
70 $aArguments = parent::render($oOutputFormat);
71 return "{$this->sName}({$aArguments})";
72 }
73 }
74