minor doc polishing
This commit is contained in:
@@ -696,9 +696,9 @@
|
||||
|
||||
<programlisting><system.web>
|
||||
<httpHandlers>
|
||||
<!--
|
||||
<!--
|
||||
the lines below map *any* request ending with *.ashx or *.whatever
|
||||
to the global(!) MappingHandlerFactory. Further "specialication"
|
||||
to the global(!) MappingHandlerFactory. Further "specialication"
|
||||
of which handler to map to is done within MappingHandlerFactory's configuration -
|
||||
use MappingHandlerFactoryConfigurer for this (see below)
|
||||
-->
|
||||
@@ -737,10 +737,10 @@
|
||||
<object name="myCustomHandler" type="MyCustomHttpHandler, App_Code">
|
||||
<property name="MessageText" value="This text is injected via Spring" />
|
||||
</object>
|
||||
|
||||
<!--
|
||||
|
||||
<!--
|
||||
used for configuring ~/DemoHandler.ashx custom handler
|
||||
note, that this is an abstract definition because 'type' is not specified
|
||||
note, that this is an abstract definition because 'type' is not specified
|
||||
-->
|
||||
<object name="DemoHandler.ashx">
|
||||
<property name="OutputText">
|
||||
@@ -880,7 +880,7 @@ class MyControl : Control, ISupportsWebDependencyInjection
|
||||
is shown below</para>
|
||||
|
||||
<programlisting language="myxml"><spring:Panel runat="server"
|
||||
suppressDependencyInjection="true"
|
||||
suppressDependencyInjection="true"
|
||||
renderContainerTag="false">
|
||||
|
||||
.. put your heavy controls here - they won't be touched by DI
|
||||
@@ -1398,12 +1398,12 @@ class MyControl : Control, ISupportsWebDependencyInjection
|
||||
{
|
||||
void BindSourceToTarget(object source, object target, ValidationErrors validationErrors);
|
||||
|
||||
void BindSourceToTarget(object source, object target, ValidationErrors validationErrors,
|
||||
void BindSourceToTarget(object source, object target, ValidationErrors validationErrors,
|
||||
IDictionary variables);
|
||||
|
||||
void BindTargetToSource(object source, object target, ValidationErrors validationErrors);
|
||||
|
||||
void BindTargetToSource(object source, object target, ValidationErrors validationErrors,
|
||||
void BindTargetToSource(object source, object target, ValidationErrors validationErrors,
|
||||
IDictionary variables);
|
||||
|
||||
void SetErrorMessage(string messageId, params string[] errorProviders);
|
||||
@@ -1448,7 +1448,7 @@ class MyControl : Control, ISupportsWebDependencyInjection
|
||||
IBinding AddBinding(string sourceExpression, string targetExpression);
|
||||
IBinding AddBinding(string sourceExpression, string targetExpression, BindingDirection direction);
|
||||
IBinding AddBinding(string sourceExpression, string targetExpression, IFormatter formatter);
|
||||
IBinding AddBinding(string sourceExpression, string targetExpression, BindingDirection direction,
|
||||
IBinding AddBinding(string sourceExpression, string targetExpression, BindingDirection direction,
|
||||
IFormatter formatter);
|
||||
}</programlisting>As you can see, this interface has a number of overloaded
|
||||
<literal>AddBinding</literal> methods. The first one,
|
||||
@@ -1712,7 +1712,7 @@ protected override void InitializeDataBindings()
|
||||
}</programlisting></para>
|
||||
|
||||
<note>
|
||||
Due to the fact, that browsers don't send the values of unchecked checkboxes, you can't use HttpRequestListBindingContainer with <input type="checkbox" > html controls.
|
||||
Due to the fact, that browsers don't send the values of unchecked checkboxes, you can't use HttpRequestListBindingContainer with <input type="checkbox" > html controls.
|
||||
</note>
|
||||
</sect3>
|
||||
</sect2>
|
||||
@@ -1796,7 +1796,7 @@ protected override void InitializeDataBindings()
|
||||
</itemizedlist>
|
||||
|
||||
<note>
|
||||
The Visual Studio Web Form Editor will of course complain about binding attributes because it doesn't know them. You can safely ignore those warnings.
|
||||
The Visual Studio Web Form Editor will of course complain about binding attributes because it doesn't know them. You can safely ignore those warnings.
|
||||
</note>
|
||||
</sect2>
|
||||
|
||||
@@ -2481,7 +2481,7 @@ private void SetLanguage(object sender, CommandEventArgs e)
|
||||
<property name="UserManager">
|
||||
<ref object="userManager"/>
|
||||
</property>
|
||||
|
||||
|
||||
<property name="Results">
|
||||
<dictionary>
|
||||
<entry key="userSaved" value="redirect:UserRegistered.aspx?status=Registration Successful,user=${UserInfo}"/>
|
||||
@@ -2572,15 +2572,15 @@ protected override void OnInit(EventArgs e)
|
||||
given resultmode string with an <literal>IResultFactory</literal>
|
||||
implementation. Here is an example</para>
|
||||
|
||||
<programlisting>class MySpecialResultLogic : IResult
|
||||
<programlisting language="csharp">class MySpecialResultLogic : IResult
|
||||
{
|
||||
...
|
||||
}
|
||||
|
||||
class MySpecialResultLogicFactory : IResultFactory
|
||||
{
|
||||
IResult Create( string mode, string expression ) {
|
||||
/* ... convert 'expression' into MySpecialResultLogic */
|
||||
IResult Create( string mode, string expression ) {
|
||||
/* ... convert 'expression' into MySpecialResultLogic */
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2591,7 +2591,7 @@ ResultFactoryRegistry.RegisterResultFactory( "mySpecialMode", new MySpecialResul
|
||||
<para>You would then use the custom 'continue' mode in your page as
|
||||
shown below</para>
|
||||
|
||||
<programlisting>// configure your Results
|
||||
<programlisting language="xml"><-- configure your Results -->
|
||||
<object type="mypage.aspx">
|
||||
<property name="Results">
|
||||
<dictionary>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/*
|
||||
* Copyright 2002-2008 the original author or authors.
|
||||
@@ -69,7 +69,7 @@
|
||||
an easy manner. When we are done, we will be able to define object
|
||||
definitions of type <literal>Regex</literal> like this:</para>
|
||||
|
||||
<programlisting language="myxml"><myns:regex id="regex"
|
||||
<programlisting language="myxml"><myns:regex id="regex"
|
||||
pattern="(^\d{5}$)|(^\d{5}-\d{4}$)"
|
||||
options="Compiled"/>
|
||||
</programlisting>
|
||||
@@ -89,11 +89,11 @@
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns:objects="http://www.springframework.net"
|
||||
xmlns:vs="http://schemas.microsoft.com/Visual-Studio-Intellisense"
|
||||
targetNamespace="http://www.mycompany.com/schema/myns"
|
||||
targetNamespace="http://www.mycompany.com/schema/myns"
|
||||
elementFormDefault="qualified"
|
||||
attributeFormDefault="unqualified"
|
||||
vs:friendlyname="Spring Regex Configuration" vs:ishtmlschema="false"
|
||||
vs:iscasesensitive="true" vs:requireattributequotes="true"
|
||||
vs:friendlyname="Spring Regex Configuration" vs:ishtmlschema="false"
|
||||
vs:iscasesensitive="true" vs:requireattributequotes="true"
|
||||
vs:defaultnamespacequalifier="" vs:defaultnsprefix=""
|
||||
>
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
</xsd:complexContent>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
|
||||
|
||||
</xsd:schema> </programlisting>
|
||||
|
||||
<para>The emphasized line contains an extension base for all tags that
|
||||
@@ -260,18 +260,17 @@ namespace CustomNamespace
|
||||
|
||||
protected override Type GetObjectType(XmlElement element)
|
||||
{
|
||||
return typeof (Regex); <co
|
||||
id="extensible-xml-parser-simpledateformat-co-2" />
|
||||
return typeof (Regex); <co id="extensible-xml-parser-simpledateformat-co-2" />
|
||||
}
|
||||
|
||||
protected override void DoParse(XmlElement element, ObjectDefinitionBuilder builder)
|
||||
{
|
||||
<lineannotation> // this will never be null since the schema explicitly requires that a value be supplied</lineannotation>
|
||||
// this will never be null since the schema explicitly requires that a value be supplied
|
||||
string pattern = element.GetAttribute("pattern");
|
||||
builder.AddConstructorArg(pattern);
|
||||
|
||||
<lineannotation> // this however is an optional property</lineannotation>
|
||||
string options = element.GetAttribute("options");
|
||||
// this however is an optional property
|
||||
string options = element.GetAttribute("options");
|
||||
if (StringUtils.HasText(options))
|
||||
{
|
||||
RegexOptions regexOptions = (RegexOptions)Enum.Parse(typeof (RegexOptions), options);
|
||||
@@ -339,8 +338,8 @@ namespace CustomNamespace
|
||||
<programlisting language="myxml"><configuration>
|
||||
|
||||
<configSections>
|
||||
<sectionGroup name="spring">
|
||||
<section name="parsers" type="Spring.Context.Support.NamespaceParsersSectionHandler, Spring.Core"/>
|
||||
<sectionGroup name="spring">
|
||||
<section name="parsers" type="Spring.Context.Support.NamespaceParsersSectionHandler, Spring.Core"/>
|
||||
</sectionGroup>
|
||||
</configSections>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user