/[cvs]/bareface/yakka/library/YakkaPage.php
ViewVC logotype

Diff of /bareface/yakka/library/YakkaPage.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1 by bareface, Sun Jan 5 00:22:25 2003 UTC revision 1.2 by bareface, Mon Jan 6 13:31:56 2003 UTC
# Line 129  class YakkaPage extends YakkaPermitableO Line 129  class YakkaPage extends YakkaPermitableO
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          }          }
# Line 146  class YakkaPage extends YakkaPermitableO Line 167  class YakkaPage extends YakkaPermitableO
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)

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed