Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

DTD does not allow content for cache-ref #779

@GoogleCodeExporter

Description

@GoogleCodeExporter
What version of the MyBatis are you using?
3.1.1

Hi,


I would like to create a plugin for the mybatis generator that automatically 
adds a cache-ref element in the sqlMap document. Very similar to the supplied 
CachePlugin.

However it is not possible to add any content to the cache-ref element, not 
even a comment as per the DTD (ie: <!ELEMENT cache-ref EMPTY>).

Would it be possible to modify the DTD to allow the following:

  <cache-ref namespace="com.mycompany.SharedCache">
    <!--
      WARNING - @mbggenerated
      This element is automatically generated by MyBatis Generator, do not modify.
    -->
  </cache-ref>

I`m not a DTD expert but I believe this would work:
<!ELEMENT cache-ref (#PCDATA)*>


Without that @mbggenerated comment, a new cache-ref element gets added every 
time we run the mybatis generator.

I'm using the maven plugin, but I don't think it matters.

Cheers

Original issue reported on code.google.com by [email protected] on 20 Feb 2013 at 1:54

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions