(STWriter out, InstanceScope scope, Object o, String[] options)
| 742 | } |
| 743 | |
| 744 | protected int writePOJO(STWriter out, InstanceScope scope, Object o, String[] options) throws IOException { |
| 745 | String formatString = null; |
| 746 | if ( options!=null ) formatString = options[Option.FORMAT.ordinal()]; |
| 747 | // ask the native group defining the surrounding template for the renderer |
| 748 | AttributeRenderer r = scope.st.impl.nativeGroup.getAttributeRenderer(o.getClass()); |
| 749 | String v; |
| 750 | if ( r!=null ) v = r.toString(o, formatString, locale); |
| 751 | else v = o.toString(); |
| 752 | int n; |
| 753 | if ( options!=null && options[Option.WRAP.ordinal()] !=null ) { |
| 754 | n = out.write(v, options[Option.WRAP.ordinal()]); |
| 755 | } |
| 756 | else { |
| 757 | n = out.write(v); |
| 758 | } |
| 759 | return n; |
| 760 | } |
| 761 | |
| 762 | protected int getExprStartChar(InstanceScope scope) { |
| 763 | Interval templateLocation = scope.st.impl.sourceMap[scope.ip]; |
no test coverage detected