Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
bbda52a4
Commit
bbda52a4
authored
Feb 25, 2010
by
beberlei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[2.0] DDC-376 - Fix in XML Mapping Driver 'inheritance-type' attribute.
parent
d0c9d5b5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
3 deletions
+11
-3
UPGRADE_TO_2_0
UPGRADE_TO_2_0
+7
-0
XmlDriver.php
lib/Doctrine/ORM/Mapping/Driver/XmlDriver.php
+2
-1
MappingException.php
lib/Doctrine/ORM/Mapping/MappingException.php
+2
-2
No files found.
UPGRADE_TO_2_0
View file @
bbda52a4
...
...
@@ -12,6 +12,13 @@ be implemented by using the @columnDefinition annotation (or the approriate XML
Additionally keep in mind that Doctrine's focus in on objects and you can specifiy default values for an Entitiy's
mapped fields inside PHP easily. Upon persist() invocation these values are saved as if they were default values.
## Partial Objects
## XML Mapping Driver
The 'inheritance-type' attribute changed to take last bit of ClassMetadata constant names, i.e.
NONE, SINGLE_TABLE, INHERITANCE_TYPE_JOINED
# Upgrade from 2.0-ALPHA3 to 2.0-ALPHA4
## CLI Controller changes
...
...
lib/Doctrine/ORM/Mapping/Driver/XmlDriver.php
View file @
bbda52a4
...
...
@@ -70,7 +70,8 @@ class XmlDriver extends AbstractFileDriver
}
if
(
isset
(
$xmlRoot
[
'inheritance-type'
]))
{
$metadata
->
setInheritanceType
((
string
)
$xmlRoot
[
'inheritance-type'
]);
$inheritanceType
=
(
string
)
$xmlRoot
[
'inheritance-type'
];
$metadata
->
setInheritanceType
(
constant
(
'Doctrine\ORM\Mapping\ClassMetadata::INHERITANCE_TYPE_'
.
$inheritanceType
));
}
// Evaluate <discriminator-column...>
...
...
lib/Doctrine/ORM/Mapping/MappingException.php
View file @
bbda52a4
...
...
@@ -34,9 +34,9 @@ class MappingException extends \Doctrine\ORM\ORMException
.
" Every Entity must have an identifier/primary key."
);
}
public
static
function
invalidInheritanceType
(
$type
)
public
static
function
invalidInheritanceType
(
$
entityName
,
$
type
)
{
return
new
self
(
"The inheritance type '
$type
' does not exist."
);
return
new
self
(
"The inheritance type '
$type
'
specified for '
$entityName
'
does not exist."
);
}
public
static
function
generatorNotAllowedWithCompositeId
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment