129 |
$this->version = $version; |
$this->version = $version; |
130 |
} |
} |
131 |
|
|
132 |
|
function increaseReleaseVersion() { |
133 |
|
if (preg_match("/^(\d)?\..*/", $this->version, $matches)) { |
134 |
|
$buildNumber = (int)$matches[1] + 1; |
135 |
|
$this->version = $buildNumber.".0.0"; |
136 |
|
} |
137 |
|
} |
138 |
|
|
139 |
|
function increaseMajorVersion() { |
140 |
|
if (preg_match("/^(.*)\.(\d)?\./", $this->version, $matches)) { |
141 |
|
$buildNumber = (int)$matches[2] + 1; |
142 |
|
$this->version = $matches[1].".".$buildNumber.".0"; |
143 |
|
} |
144 |
|
} |
145 |
|
|
146 |
|
function increaseMinorVersion() { |
147 |
|
if (preg_match("/(.*)\.(\d)?$/", $this->version, $matches)) { |
148 |
|
$buildNumber = (int)$matches[2] + 1; |
149 |
|
$this->version = $matches[1].".".$buildNumber; |
150 |
|
} |
151 |
|
} |
152 |
|
|
153 |
function &getCreateUser() { |
function &getCreateUser() { |
154 |
return $this->createUser; |
return $this->createUser; |
155 |
} |
} |
167 |
} |
} |
168 |
|
|
169 |
function toXml() { |
function toXml() { |
170 |
$xml = "<page id='$this->id' name='$this->name' islatest='".YakkaSerialize::boolToString($this->isLatest)."' createdate='".date("Y-m-d H:i:s", $this->createTimestamp)."' modifydate='".date("Y-m-d H:i:s", $this->modifyTimestamp)."'"; |
$xml = "<page id='$this->id' name='$this->name' islatest='".YakkaSerialize::boolToString($this->isLatest)."' createdate='".date("Y-m-d H:i:s", $this->createTimestamp)."' modifydate='".date("Y-m-d H:i:s", $this->modifyTimestamp)."' version='$this->version'"; |
171 |
if ($this->createUser) |
if ($this->createUser) |
172 |
$xml .= " create-user-id='".$this->createUser->getId()."'"; |
$xml .= " create-user-id='".$this->createUser->getId()."'"; |
173 |
if ($this->modifyUser) |
if ($this->modifyUser) |