Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

v5.4.0

  • Loading branch information...
commit 7ac295fa35f5fc9f9c2094d8b7c3add815666ee2 1 parent 3f5fcee
@groue authored
Showing with 299 additions and 116 deletions.
  1. +4 −0 Guides/introduction.md
  2. +15 −2 Guides/partials.md
  3. +83 −28 Guides/template_repositories.md
  4. +2 −1  Guides/variable_tag_helpers.md
  5. +1 −1  README.md
  6. +18 −4 RELEASE_NOTES.md
  7. +2 −2 Reference/html/Classes/GRMustache.html
  8. +2 −2 Reference/html/Classes/GRMustacheDynamicPartial.html
  9. +2 −2 Reference/html/Classes/GRMustacheFilter.html
  10. +2 −2 Reference/html/Classes/GRMustacheHelper.html
  11. +2 −2 Reference/html/Classes/GRMustacheInvocation.html
  12. +2 −2 Reference/html/Classes/GRMustacheSection.html
  13. +2 −2 Reference/html/Classes/GRMustacheSectionHelper.html
  14. +2 −2 Reference/html/Classes/GRMustacheSectionTagHelper.html
  15. +2 −2 Reference/html/Classes/GRMustacheSectionTagRenderingContext.html
  16. +2 −2 Reference/html/Classes/GRMustacheTemplate.html
  17. +2 −2 Reference/html/Classes/GRMustacheTemplateRepository.html
  18. +2 −2 Reference/html/Classes/GRMustacheVariable.html
  19. +2 −2 Reference/html/Classes/GRMustacheVariableHelper.html
  20. +2 −2 Reference/html/Classes/GRMustacheVariableTagHelper.html
  21. +2 −2 Reference/html/Classes/GRMustacheVariableTagRenderingContext.html
  22. +2 −2 Reference/html/Protocols/GRMustacheFilter.html
  23. +2 −2 Reference/html/Protocols/GRMustacheHelper.html
  24. +2 −2 Reference/html/Protocols/GRMustacheSectionHelper.html
  25. +2 −2 Reference/html/Protocols/GRMustacheSectionTagHelper.html
  26. +2 −2 Reference/html/Protocols/GRMustacheTemplateDelegate.html
  27. +11 −8 Reference/html/Protocols/GRMustacheTemplateRepositoryDataSource.html
  28. +2 −2 Reference/html/Protocols/GRMustacheVariableHelper.html
  29. +2 −2 Reference/html/Protocols/GRMustacheVariableTagHelper.html
  30. +5 −5 Reference/html/hierarchy.html
  31. +5 −5 Reference/html/index.html
  32. +92 −2 include/GRMustacheAvailabilityMacros.h
  33. +2 −2 include/GRMustacheError.h
  34. +4 −4 include/GRMustacheTemplateDelegate.h
  35. +12 −9 include/GRMustacheTemplateRepository.h
  36. +1 −1  include/GRMustacheVersion.h
  37. BIN  lib/libGRMustache5-MacOS.a
  38. BIN  lib/libGRMustache5-iOS.a
View
4 Guides/introduction.md
@@ -32,6 +32,10 @@ Genuine Mustache falls short on a few topics. GRMustache implements features tha
Filters are documented in [filters.md](filters.md).
+- **support for partial templates in a file system hierarchy**.
+
+ Use relative or absolute paths to your partial templates in your partial tags: see [partials.md](partials.md).
+
- "**overridable partials**", aka "template inheritance", as in [hogan.js](http://twitter.github.com/hogan.js/) and [spullara/mustache.java](https://github.com/spullara/mustache.java).
Overridable partials are documented in [partials.md](partials.md).
View
17 Guides/partials.md
@@ -37,7 +37,7 @@ Partials in the file system
When you identify a template through a URL or a file path, you are able to navigate through a hierarchy of directories and partial files.
-The partial tag `{{>name}}` actually interprets the *name* as a *path*, and loads the template relatively to the embedding template. For example, given the following hierarchy:
+The partial tag `{{>name}}` actually interprets the *name* as a *path*, and loads the template *relatively* to the embedding template. For example, given the following hierarchy:
- templates
- a.mustache
@@ -60,7 +60,20 @@ GRMustacheTemplate *bTemplate = [GRMustacheTemplate templateFromContentsOfFile:b
[bTemplate render...];
```
+### Absolute paths to partials
+When your templates are stored in a hierarchy of directories, you sometimes need to refer to a partial template in an absolute way, that does not depend of the location of the embedding template.
+
+Compare:
+
+ `{{> partials/header }}`
+ `{{> /partials/header }}` {{! with a leading slash }}
+
+The first partial tag provides a *relative path*, and refers to a different template, depending on the path of the including template.
+
+The latter always references the same partial, with an *absolute path*.
+
+Absolute partial paths need a root, and the objects that set this root are `GRMustacheTemplateRepository` objects. The rest of the story is documented at [template_repositories.md](template_repositories.md).
### Template Hierarchy in an NSBundle
@@ -83,7 +96,7 @@ GRMustacheTemplate *bTemplate = [GRMustacheTemplate templateFromContentsOfFile:b
[bTemplate render...];
```
-You may also use the `GRMustacheTemplateRepository` class, that will be introduced in the [template_repositories.md](template_repositories.md):
+You may also use the `GRMustacheTemplateRepository` class, that is documented in [template_repositories.md](template_repositories.md):
```objc
// Repository of templates stored in templates directory resource:
View
111 Guides/template_repositories.md
@@ -3,32 +3,40 @@
Template repositories
=====================
-The GRMustacheTemplateRepository class allows you to load template strings and partials from various data sources.
+You use the `GRMustacheTemplateRepository` class when you want to choose a specific source where your templates and partials are loaded from.
+This may happen in these two particular cases:
-Loading templates and partials from the file system
----------------------------------------------------
+- when the `[GRMustacheTemplate templateFrom...]` methods do not fit your needs (see [templates.md](templates.md)).
+
+ For example, your templates are not stored in the file system, or they are not encoded as UTF8.
+
+- when your templates are stored in a hierarchy of directories, and you want to specify an absolute path in a [partial tag](partials.md).
-The GRMustacheTemplate class itself provides [convenient methods](templates.md) for loading UTF8-encoded templates from bundles and from the file system.
+ `{{> header}}` loads a `header` partial template stored next to its enclosing template, but `{{> /partials/header}}`, with a leading slash, loads a template located at the absolute path `/partials/header` from the root of the template repository.
+
+ This absolute reference to a partial template reveals useful when implementing robust [variable tag helpers](variable_tag_helpers.md) that use partial templates.
+
+Both use cases are covered by the `GRMustacheTemplateRepository` methods documented below.
-GRMustacheTemplateRepository fills the remaining less-common needs.
-It ships with the following class methods:
+Loading templates and partials from the file system
+---------------------------------------------------
```objc
@interface GRMustacheTemplateRepository : NSObject
// Loads templates and partials from a directory, with "mustache" extension,
-// encoded in UTF8 (from MacOS 10.6 and iOS 4.0).
+// encoded in UTF8.
+ (id)templateRepositoryWithBaseURL:(NSURL *)url;
// Loads templates and partials from a directory, with provided extension,
-// encoded in UTF8 (from MacOS 10.6 and iOS 4.0).
+// encoded in UTF8.
+ (id)templateRepositoryWithBaseURL:(NSURL *)url
templateExtension:(NSString *)ext;
// Loads templates and partials from a directory, with provided extension,
-// encoded in provided encoding (from MacOS 10.6 and iOS 4.0).
+// encoded in provided encoding.
+ (id)templateRepositoryWithBaseURL:(NSURL *)url
templateExtension:(NSString *)ext
encoding:(NSStringEncoding)encoding;
@@ -68,8 +76,8 @@ It ships with the following class methods:
For instance:
```objc
-NSString *path = @"path/to/templates";
-GRMustacheTemplateRepository *repository = [GRMustacheTemplate templateRepositoryWithDirectory:path];
+NSString *templatesPath = @"path/to/templates";
+GRMustacheTemplateRepository *repository = [GRMustacheTemplateRepository templateRepositoryWithDirectory:templatesPath];
```
You may now load a template:
@@ -82,20 +90,64 @@ GRMustacheTemplate *template = [repository templateForName:@"document" error:NUL
You may also have the repository parse a template string. Only partials would then be loaded from the repository:
```objc
-// Would load path/to/templates/partial.mustache
-GRMustacheTemplate *template = [repository templateFromString:@"...{{> partial}}..." error:NULL];
+// Would load path/to/templates/partials/header.mustache
+GRMustacheTemplate *template = [repository templateFromString:@"...{{> partials/header}}..." error:NULL];
```
-
-The rendering is done as usual:
+
+
+The rendering is done as usual (see [templates.md](templates.md)):
```objc
NSString *rendering = [template renderObject:...];
```
+### Absolute paths to partial templates
+
+Assuming your templates are stored in a hierarchy of directories, you may sometimes have to refer to the same [partial template](partials.md) from different templates stored at different levels of your hierarchy.
+
+For example, those three templates all include the same `shared/header.mustache` partial:
+
+ a.mustache:
+ {{> shared/header }} {{! relative path to shared/header }}
+
+ shared/b.mustache
+ {{> header }} {{! relative path to shared/header }}
+
+ ios/c.mustache
+ {{> ../shared/header }} {{! relative path to shared/header }}
+
+In this case, use an absolute path in your partial tags, starting with a slash, and explicitly choose the root of absolute paths with a `GRMustacheTemplateRepository` object:
+
+ a.mustache:
+ {{> /shared/header }} {{! absolute path to shared/header }}
+
+ shared/b.mustache
+ {{> /shared/header }} {{! absolute path to shared/header }}
+
+ ios/c.mustache
+ {{> /shared/header }} {{! absolute path to shared/header }}
+
+```objc
+NSString *templatesPath = @"path/to/templates";
+GRMustacheTemplateRepository *repository = [GRMustacheTemplateRepository templateRepositoryWithDirectory:templatesPath];
+
+// Loads path/to/templates/a.mustache, and provides a root for
+// absolute partial tags:
+GRMustacheTemplate aTemplate = [repository templateForName:@"a"];
+NSString *rendering = [aTemplate renderObject:...];
+```
+
+### Absolute paths to partials and helpers
+
+When you implement a variable or section tag helper that uses a partial, you want it to always include the same partial, whichever is the hierarchical position of the templates that use it. Again, absolute paths to partials are the solution.
+
+See [variable_tag_helpers.md](variable_tag_helpers.md) and [section_tag_helpers.md](section_tag_helpers.md) for more information about tag helpers.
+
+
Loading templates and partials from a dictionary of template strings
--------------------------------------------------------------------
-Use the following GRMustacheTemplateRepository class method:
+When your template and partial strings are stored in memory, store them in a dictionary, and use the following GRMustacheTemplateRepository class method:
```objc
@interface GRMustacheTemplateRepository : NSObject
@@ -129,17 +181,17 @@ And finally render:
```
-GRMustacheTemplateRepositoryDataSource protocol
------------------------------------------------
+GRMustacheTemplateRepository Data Source
+----------------------------------------
-Finally, you may implement the GRMustacheTemplateRepositoryDataSource protocol in order to load templates for unimagined sources.
+Finally, you may implement the `GRMustacheTemplateRepositoryDataSource` protocol in order to load templates for unimagined sources.
```objc
/**
- * The protocol for a GRMustacheTemplateRepository's dataSource.
+ * The protocol for a GRMustacheTemplateRepository's data source.
*
- * The dataSource's responsability is to provide Mustache template strings for
- * template and partial names.
+ * The responsability of the data source's is to provide Mustache template
+ * strings for template and partial names.
*
* @see GRMustacheTemplateRepository
*/
@@ -157,10 +209,10 @@ Finally, you may implement the GRMustacheTemplateRepositoryDataSource protocol i
* For instance, a file-based data source may use NSString objects containing
* paths to the templates.
*
- * You should try to choose "human-readable" template IDs. That is because
- * template IDs are embedded in the description of errors that may happen during
- * a template processing, in order to help the library user locate, and fix, the
- * faulting template.
+ * You should try to choose "human-readable" template IDs, because template IDs
+ * are embedded in the description of errors that may happen during a template
+ * processing, in order to help the library user locate, and fix, the faulting
+ * template.
*
* Whenever relevant, template and partial hierarchies are supported via the
* _baseTemplateID_ parameter: it contains the template ID of the enclosing
@@ -170,9 +222,12 @@ Finally, you may implement the GRMustacheTemplateRepositoryDataSource protocol i
*
* Not all data sources have to implement hierarchies: they can simply ignore
* this parameter.
+ *
+ * Data sources that implement hierarchies have to implement their own support
+ * for absolute partial paths.
*
- * The returned value can be nil: the library user would then eventually get an
- * NSError of domain GRMustacheErrorDomain and code
+ * The return value of this method can be nil: the library user would then
+ * eventually get an NSError of domain GRMustacheErrorDomain and code
* GRMustacheErrorCodeTemplateNotFound.
*
* @param templateRepository The GRMustacheTemplateRepository asking for a
View
3  Guides/variable_tag_helpers.md
@@ -48,7 +48,7 @@ The `GRMustacheVariableTagRenderingContext` parameter provides the following met
```
The `renderTemplateString:error:` method returns the *rendering of a template string*. The eventual `{{tags}}` in the template string are interpolated. Should you provide a template string with a syntax error, or that loads a missing template partial, the method would return nil, and sets its error argument.
-The `renderTemplateNamed:error:` method is a shortcut that returns the *rendering of a partial template*, given its name.
+The `renderTemplateNamed:error:` method is a shortcut that returns the *rendering of a partial template*, given its name. If your templates are stored in a directory hierarchy, you might want to provide the absolute path to the partial in a [template repository](template_repositories.md).
### Purpose of variable tag helpers
@@ -199,6 +199,7 @@ NSString *rendering = [template render:data];
However, keep in mind the longer version that uses `renderTemplateNamed:error:`, that we'll find again in some interesting examples below.
+And again, if your templates are stored in a directory hierarchy, you might want to provide the absolute path to the partial in a [template repository](template_repositories.md).
Examples
--------
View
2  README.md
@@ -3,7 +3,7 @@ GRMustache
GRMustache is a production-ready implementation of [Mustache](http://mustache.github.com/) templates for MacOS Cocoa and iOS.
-**September 26th, 2012: GRMustache 5.3 is out.** [Release notes](GRMustache/blob/master/RELEASE_NOTES.md)
+**September 28th, 2012: GRMustache 5.4 is out.** [Release notes](GRMustache/blob/master/RELEASE_NOTES.md)
Don't miss a single release: follow [@GRMustache](http://twitter.com/GRMustache) on Twitter.
View
22 RELEASE_NOTES.md
@@ -4,15 +4,29 @@ GRMustache Release Notes
You can compare the performances of GRMustache versions at https://github.com/groue/GRMustacheBenchmark.
+## v5.4.0
+
+### Support for templates and partials stored in a hierarchy of directories
+
+When your templates are stored in a hierarchy of directories, you need to refer to [partial templates](Guides/partials.md) in both relative and absolute ways, depending on the context.
+
+Your [variable tag helpers](Guides/variable_tag_helpers.md) and your [section tag helpers](Guides/section_tag_helpers.md) will typically use absolute paths, in order to always include the same partial template, regardless of the hierarchical position of the templates that use them.
+
+Relative partial paths look like regular Mustache partial tags: `{{> header }}`, `{{> partials/header }}`.
+
+GRMustache v5.4.0 brings absolute paths, that start with a slash: `{{> /path/to/partial }}`.
+
+The root of absolute paths is specified with `GRMustacheTemplateRepository` objects: check the full story at [Guides/template_repositories.md](Guides/template_repositories.md).
+
## v5.3.0
-**API cleanup**
+### API cleanup
The introduction of variable tag helpers in v5.1.0 introduced many confusing APIs. Those are still there, but deprecated.
No new feature has been added, but semantics have been much improved. Many thanks to [@pierlo](https://github.com/pierlo) for his help.
-### Helpers API changes
+**Helpers API changes**
`GRMustacheVariableTagHelper` replaces `GRMustacheVariableHelper`. See [Guides/variable_tag_helpers.md](Guides/variable_tag_helpers.md).
@@ -43,11 +57,11 @@ No new feature has been added, but semantics have been much improved. Many thank
@end
```
-### GRMustacheTemplateDelegate API changes
+**GRMustacheTemplateDelegate API changes**
In the `GRMustacheInterpretation` enumeration, `GRMustacheSectionTagInterpretation` replaces `GRMustacheInterpretationSection`, and `GRMustacheVariableTagInterpretation` replaces `GRMustacheInterpretationVariable`.
-### GRMustacheTemplate API changes
+**GRMustacheTemplate API changes**
`[GRMustacheTemplate renderObjectsFromArray:]` and `[GRMustacheTemplate renderObjectsFromArray:withFilters:]` replace `[GRMustacheTemplate renderObjectsInArray:]` and `[GRMustacheTemplate renderObjectsInArray:withFilters:]`.
View
4 Reference/html/Classes/GRMustache.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -306,7 +306,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheDynamicPartial.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -229,7 +229,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheFilter.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -232,7 +232,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -225,7 +225,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheInvocation.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -307,7 +307,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheSection.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -385,7 +385,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheSectionHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -235,7 +235,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheSectionTagHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -232,7 +232,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheSectionTagRenderingContext.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -379,7 +379,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheTemplate.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -2224,7 +2224,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheTemplateRepository.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -1548,7 +1548,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheVariable.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -311,7 +311,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheVariableHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -235,7 +235,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheVariableTagHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -233,7 +233,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Classes/GRMustacheVariableTagRenderingContext.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -307,7 +307,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheFilter.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -232,7 +232,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -122,7 +122,7 @@ <h2 class="subtitle subtitle-overview">Overview</h2>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheSectionHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -236,7 +236,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheSectionTagHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -233,7 +233,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheTemplateDelegate.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -459,7 +459,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
19 Reference/html/Protocols/GRMustacheTemplateRepositoryDataSource.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -247,10 +247,10 @@ <h4 class="method-subtitle">Discussion</h4>
<p>For instance, a file-based data source may use NSString objects containing
paths to the templates.</p>
-<p>You should try to choose &ldquo;human-readable&rdquo; template IDs. That is because
-template IDs are embedded in the description of errors that may happen during
-a template processing, in order to help the library user locate, and fix, the
-faulting template.</p>
+<p>You should try to choose &ldquo;human-readable&rdquo; template IDs, because template IDs
+are embedded in the description of errors that may happen during a template
+processing, in order to help the library user locate, and fix, the faulting
+template.</p>
<p>Whenever relevant, template and partial hierarchies are supported via the
<em>baseTemplateID</em> parameter: it contains the template ID of the enclosing
@@ -261,8 +261,11 @@ <h4 class="method-subtitle">Discussion</h4>
<p>Not all data sources have to implement hierarchies: they can simply ignore
this parameter.</p>
-<p>The returned value can be nil: the library user would then eventually get an
-NSError of domain GRMustacheErrorDomain and code
+<p>Data sources that implement hierarchies have to implement their own support
+for absolute partial paths.</p>
+
+<p>The return value of this method can be nil: the library user would then
+eventually get an NSError of domain GRMustacheErrorDomain and code
GRMustacheErrorCodeTemplateNotFound.</p>
</div>
@@ -375,7 +378,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheVariableHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -236,7 +236,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
4 Reference/html/Protocols/GRMustacheVariableTagHelper.html
@@ -12,7 +12,7 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="../index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="../index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="../index.html">Gwendal Roué</a>
</div>
@@ -233,7 +233,7 @@ <h4 class="method-subtitle">Declared In</h4>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
10 Reference/html/hierarchy.html
@@ -2,7 +2,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>GRMustache 5.3 Hierarchy</title>
+ <title>GRMustache 5.4 Hierarchy</title>
<link rel="stylesheet" type="text/css" href="css/styles.css" media="all" />
<link rel="stylesheet" type="text/css" media="print" href="css/stylesPrint.css" />
<meta name="generator" content="appledoc 2.0.6 (build 789)" />
@@ -10,12 +10,12 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="index.html">Gwendal Roué</a>
</div>
<div id="title" role="banner">
- <h1 class="hideInXcode">GRMustache 5.3 Hierarchy</h1>
+ <h1 class="hideInXcode">GRMustache 5.4 Hierarchy</h1>
</div>
<ul id="headerButtons" role="toolbar"></ul>
</header>
@@ -26,7 +26,7 @@ <h1 class="hideInXcode">GRMustache 5.3 Hierarchy</h1>
</div>
<div id="header">
<div class="section-header">
- <h1 class="title title-header">GRMustache 5.3 Hierarchy</h1>
+ <h1 class="title title-header">GRMustache 5.4 Hierarchy</h1>
</div>
</div>
<div id="container">
@@ -115,7 +115,7 @@ <h2 class="index-title">Protocol References</h2>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
10 Reference/html/index.html
@@ -2,7 +2,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>GRMustache 5.3 Reference</title>
+ <title>GRMustache 5.4 Reference</title>
<link rel="stylesheet" type="text/css" href="css/styles.css" media="all" />
<link rel="stylesheet" type="text/css" media="print" href="css/stylesPrint.css" />
<meta name="generator" content="appledoc 2.0.6 (build 789)" />
@@ -10,12 +10,12 @@
<body>
<header id="top_header">
<div id="library" class="hideInXcode">
- <h1><a id="libraryTitle" href="index.html">GRMustache 5.3 </a></h1>
+ <h1><a id="libraryTitle" href="index.html">GRMustache 5.4 </a></h1>
<a id="developerHome" href="index.html">Gwendal Roué</a>
</div>
<div id="title" role="banner">
- <h1 class="hideInXcode">GRMustache 5.3 Reference</h1>
+ <h1 class="hideInXcode">GRMustache 5.4 Reference</h1>
</div>
<ul id="headerButtons" role="toolbar"></ul>
</header>
@@ -26,7 +26,7 @@ <h1 class="hideInXcode">GRMustache 5.3 Reference</h1>
</div>
<div id="header">
<div class="section-header">
- <h1 class="title title-header">GRMustache 5.3 Reference</h1>
+ <h1 class="title title-header">GRMustache 5.4 Reference</h1>
</div>
</div>
<div id="container">
@@ -107,7 +107,7 @@ <h2 class="index-title">Protocol References</h2>
<div id="footer">
<hr />
<div class="footer-copyright">
- <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-26)</span><br />
+ <p><span class="copyright">&copy; 2012 Gwendal Roué. All rights reserved. (Last updated: 2012-09-28)</span><br />
<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.6 (build 789)</a>.</span></p>
View
94 include/GRMustacheAvailabilityMacros.h
@@ -32,6 +32,7 @@
#define GRMUSTACHE_VERSION_5_1 5010
#define GRMUSTACHE_VERSION_5_2 5020
#define GRMUSTACHE_VERSION_5_3 5030
+#define GRMUSTACHE_VERSION_5_4 5040
@@ -39,10 +40,10 @@
/*
- * If max GRMustacheVersion not specified, assume 5.3
+ * If max GRMustacheVersion not specified, assume 5.4
*/
#ifndef GRMUSTACHE_VERSION_MAX_ALLOWED
-#define GRMUSTACHE_VERSION_MAX_ALLOWED GRMUSTACHE_VERSION_5_3
+#define GRMUSTACHE_VERSION_MAX_ALLOWED GRMUSTACHE_VERSION_5_4
#endif
/*
@@ -289,3 +290,92 @@
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER
+ *
+ * Used on declarations introduced in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MAX_ALLOWED < GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER UNAVAILABLE_ATTRIBUTE
+#elif GRMUSTACHE_VERSION_MIN_REQUIRED < GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER WEAK_IMPORT_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER
+#endif
+
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER_BUT_DEPRECATED
+ *
+ * Used on declarations introduced in GRMustache 5.4,
+ * and deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER_BUT_DEPRECATED AVAILABLE_GRMUSTACHE_VERSION_5_4_AND_LATER
+#endif
+
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4
+ *
+ * Used on declarations introduced in GRMustache 5.0,
+ * but later deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 DEPRECATED_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER
+#endif
+
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_1_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4
+ *
+ * Used on declarations introduced in GRMustache 5.1,
+ * but later deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_1_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 DEPRECATED_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_1_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 AVAILABLE_GRMUSTACHE_VERSION_5_1_AND_LATER
+#endif
+
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_2_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4
+ *
+ * Used on declarations introduced in GRMustache 5.2,
+ * but later deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_2_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 DEPRECATED_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_2_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 AVAILABLE_GRMUSTACHE_VERSION_5_2_AND_LATER
+#endif
+
+/*
+ * AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4
+ *
+ * Used on declarations introduced in GRMustache 5.3,
+ * but later deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 DEPRECATED_ATTRIBUTE
+#else
+#define AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_4 AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER
+#endif
+
+/*
+ * DEPRECATED_IN_GRMUSTACHE_VERSION_5_4_AND_LATER
+ *
+ * Used on types deprecated in GRMustache 5.4
+ */
+#if GRMUSTACHE_VERSION_MIN_REQUIRED >= GRMUSTACHE_VERSION_5_4
+#define DEPRECATED_IN_GRMUSTACHE_VERSION_5_4_AND_LATER DEPRECATED_ATTRIBUTE
+#else
+#define DEPRECATED_IN_GRMUSTACHE_VERSION_5_4_AND_LATER
+#endif
+
+
+
+
+
+
View
4 include/GRMustacheError.h
@@ -35,14 +35,14 @@ typedef enum {
*
* @since v1.0
*/
- GRMustacheErrorCodeParseError,
+ GRMustacheErrorCodeParseError AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER,
/**
* The error code for not found templates and partials.
*
* @since v1.0
*/
- GRMustacheErrorCodeTemplateNotFound,
+ GRMustacheErrorCodeTemplateNotFound AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER,
} GRMustacheErrorCode AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER;
View
8 include/GRMustacheTemplateDelegate.h
@@ -45,7 +45,7 @@ typedef enum {
*
* @since v5.3
*/
- GRMustacheSectionTagInterpretation = 0,
+ GRMustacheSectionTagInterpretation AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER = 0,
/**
* The value is interpreted by a Mustache variable tag such as `{{name}}`.
@@ -54,7 +54,7 @@ typedef enum {
*
* @since v5.3
*/
- GRMustacheVariableTagInterpretation,
+ GRMustacheVariableTagInterpretation AVAILABLE_GRMUSTACHE_VERSION_5_3_AND_LATER,
// Deprecated values
@@ -69,7 +69,7 @@ typedef enum {
* @since v4.1
* @deprecated v5.3
*/
- GRMustacheInterpretationSection AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_3 = GRMustacheSectionTagInterpretation,
+ GRMustacheInterpretationSection AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_3 = 0,
/**
* The value is interpreted by a Mustache variable tag such as `{{name}}`.
@@ -79,7 +79,7 @@ typedef enum {
* @since v4.1
* @deprecated v5.3
*/
- GRMustacheInterpretationVariable AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_3 = GRMustacheVariableTagInterpretation,
+ GRMustacheInterpretationVariable AVAILABLE_GRMUSTACHE_VERSION_5_0_AND_LATER_BUT_DEPRECATED_IN_GRMUSTACHE_VERSION_5_3,
} GRMustacheInterpretation;
View
21 include/GRMustacheTemplateRepository.h
@@ -58,11 +58,11 @@
* For instance, a file-based data source may use NSString objects containing
* paths to the templates.
*
- * You should try to choose "human-readable" template IDs. That is because
- * template IDs are embedded in the description of errors that may happen during
- * a template processing, in order to help the library user locate, and fix, the
- * faulting template.
- *
+ * You should try to choose "human-readable" template IDs, because template IDs
+ * are embedded in the description of errors that may happen during a template
+ * processing, in order to help the library user locate, and fix, the faulting
+ * template.
+ *
* Whenever relevant, template and partial hierarchies are supported via the
* _baseTemplateID_ parameter: it contains the template ID of the enclosing
* template, or nil when the data source is asked for a template ID for a
@@ -71,11 +71,14 @@
*
* Not all data sources have to implement hierarchies: they can simply ignore
* this parameter.
- *
- * The returned value can be nil: the library user would then eventually get an
- * NSError of domain GRMustacheErrorDomain and code
+ *
+ * Data sources that implement hierarchies have to implement their own support
+ * for absolute partial paths.
+ *
+ * The return value of this method can be nil: the library user would then
+ * eventually get an NSError of domain GRMustacheErrorDomain and code
* GRMustacheErrorCodeTemplateNotFound.
- *
+ *
* @param templateRepository The GRMustacheTemplateRepository asking for a
* template ID.
* @param name The name of the template or template partial.
View
2  include/GRMustacheVersion.h
@@ -33,7 +33,7 @@
*
* @since v1.0
*/
-#define GRMUSTACHE_MINOR_VERSION 3
+#define GRMUSTACHE_MINOR_VERSION 4
/**
* The patch-level component of GRMustache version
View
BIN  lib/libGRMustache5-MacOS.a
Binary file not shown
View
BIN  lib/libGRMustache5-iOS.a
Binary file not shown
Please sign in to comment.
Something went wrong with that request. Please try again.