The following sections should be added to your web.config. These are the default providers used by Coffee.

  <configSections>
    <sectionGroup name="Coffee">
      <section name="BindingProviders" type="Coffee.Configuration.ProvidersSection, Coffee"/>
      <section name="ParserProviders" type="Coffee.Configuration.ProvidersSection, Coffee"/>
      <section name="ConverterProviders" type="Coffee.Configuration.ProvidersSection, Coffee"/>
    </sectionGroup>
  </configSections>

...

 <Coffee>
    <BindingProviders>
      <providers>
        <add key="function" type="Coffee.BindingProviders" method="CallMethodProvider"/>
        <add key="list" type="Coffee.BindingProviders" method="ListProvider"/>
        <add key="storedproc" type="Coffee.BindingProviders" method="SQLStoredProcProvider"/>
      </providers>
    </BindingProviders>
    <ParserProviders>
      <providers>
        <add key="function" type="Coffee.ValueParserProviders" method="CallMethodProvider"/>
        <add key="control" type="Coffee.ValueParserProviders" method="ControlProvider"/>
        <add key="resource" type="Coffee.ValueParserProviders" method="ResourceProvider"/>
        <add key="session" type="Coffee.ValueParserProviders" method="SessionProvider"/>
        <!--shortcuts-->
        <add key="#" type="Coffee.ValueParserProviders" method="CallMethodProvider"/>
        <add key="!" type="Coffee.ValueParserProviders" method="ControlProvider"/>
        <add key="$" type="Coffee.ValueParserProviders" method="ResourceProvider"/>
        <add key="&amp;" type="Coffee.ValueParserProviders" method="SessionProvider"/>
      </providers>
    </ParserProviders>
    <ConverterProviders>
      <providers>
        <add key="System.Web.UI.WebControls.Unit, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" type="Coffee.ValueConverterProviders" method="WebControlsUnitProvider"/>
        <add key="System.Int32" type="Coffee.ValueConverterProviders" method="Int32Provider"/>
        <add key="System.DateTime" type="Coffee.ValueConverterProviders" method="DateTimeProvider"/>
      </providers>
    </ConverterProviders>
  </Coffee>

Last edited Jul 4, 2012 at 7:43 AM by RupertAvery, version 3

Comments

No comments yet.