Author:admin

Date:2008-09-19T14:06:51.000000Z


git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@28 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
jfiat
2008-09-19 14:06:51 +00:00
parent 4087eb614e
commit a903078386
100 changed files with 122 additions and 16 deletions

View File

@@ -1,5 +1,6 @@
[[Property:title|Eiffel CodeDom Provider Manager]]
[[Property:weight|-1]]
[[Property:uuid|089e658f-4bd8-df8f-5647-0c176c00359b]]
The Eiffel Codedom Provider Manager allows to graphically configure the Eiffel CodeDom Provider. There can be multiple configurations, each of them being associated with at least one application.
{{note| '''Note:''' The Eiffel for ASP.NET installation program will add a shortcut in the start menu to the Eiffel CodeDom Provider Manager. }}
The main dialog of the Eiffel CodeDom Provider Manager is divided into two vertical panes. The left pane contains a list of available configurations while the right pane contains the settings corresponding to the currently selected configuration. Initially the only available configuration is the '''default''' configuration which applies to all applications. The configurable settings are listed below.

View File

@@ -1,5 +1,6 @@
[[Property:title|Name Mapper]]
[[Property:weight|2]]
[[Property:uuid|82691c82-50a5-ed7f-b138-90946d094dae]]
The Name Mapper utility allows retrieving the Eiffel identifier corresponding to a .NET type name or a .NET member name. There are only two input fields in the interface: the .NET type name should be entered in the first one while the .NET member name should be entered in the second one. Once a valid .NET type name is entered in the type name input field, the tool starts searching for the corresponding Eiffel identifier. When the Name Mapper finds the corresponding Eiffel identifier, it automatically fills the .NET member name input combo box with all the member names of the corresponding type. This means that the .NET member type name can be chosen from the combo box entries or typed in (if it's typed in then the tool will autocomplete the member name).
The assemblies the tool will look into for the .NET type whose name was given in the .NET type name input field are listed below the input fields. It is possible to add new assemblies to the list by clicking the ''Add'' button. Assemblies that were added this way can be removed by clicking the ''Remove'' button after selecting the assembly from the list.
{{note| '''Note:''' Assemblies that are listed by default cannot be removed. }}

View File

@@ -1,5 +1,6 @@
[[Property:title|About the Code Document Object Model (CodeDom)]]
[[Property:weight|0]]
[[Property:uuid|46136373-34bb-94b7-1f7b-934d584cf637]]
CodeDom stands for the '''Code Document Object Model'''. CodeDom allows for representing source code in an abstract data structure. Such a representation is called a '''CodeDom tree''' as the underlying data structure uses a tree paradigm. This abstract representation can then be generated into different programming languages. Each language vendor provides its implementation of the CodeDom interfaces, this implementation is called a '''CodeDom Provider'''. Programmers can then build tools that can work with many different languages without having to know about each one, instead they just delegate code generation to each CodeDom Provider.
The CodeDom interfaces also expose types and methods that allow for parsing source code and creating the corresponding CodeDom. The current implementation of the Eiffel CodeDom Provider does not support parsing. Code generation is a much more popular useage of the CodeDom and the current version focuses on this aspect of the technology.

View File

@@ -1,5 +1,6 @@
[[Property:title|Common Scenarios]]
[[Property:weight|7]]
[[Property:uuid|15334d95-2ef5-6e1b-1754-051342bb7290]]
==ASP.NET==
Probably the most common use of the CodeDom technology is via Internet Information Services (IIS) and ASP.NET. The installation of the Eiffel for ASP.NET will configure the machine so ASP.NET pages can be written in Eiffel. Consult the [[Eiffel for ASP.NET Installation|Eiffel for ASP.NET documentation]] for details on how to write ASP.NET Eiffel pages.
==WSDL==

View File

@@ -1,5 +1,6 @@
[[Property:title|Configuration]]
[[Property:weight|3]]
[[Property:uuid|2d885f05-adcc-d8da-6515-4568fc76bcf6]]
The Eiffel Codedom Provider uses XML configuration files that define additional settings specific to Eiffel. Such settings include whether to fail on error, what events to log, where to log them etc... Each application can define its own configuration to be used when it loads the Eiffel CodeDom Provider. If an application is not associated with a configuration file then a default configuration is used.
The association between applications and configurations as well as the actual settings the configuration defines can be set in the [[Eiffel CodeDom Provider Manager|Eiffel CodeDom Provider Manager]] . Run ''ecdpman.exe'' to start the manager.

View File

@@ -1,5 +1,6 @@
[[Property:title|Eiffel Implementation]]
[[Property:weight|7]]
[[Property:uuid|3f945c36-521e-cd71-fc7b-d549a6c05a04]]
There are a few topics specific to the implementation of the Eiffel CodeDom Provider that are worth mentioning.
==Multiple Classes File==
The Eiffel compiler expects that there is only one class per source file (file with extension '''.e'''), however the CodeDom interface specification requires multiple classes to be generated in the same file (actually in the same ''stream''). The Eiffel CodeDom Provider code generator generates files with the extension '''.es''' which may contain multiple class definitions. Each class definition is separated with a special marker that the Eiffel CodeDom Provider compiler will parse to create multiple '''.e''' files - each containing a single class definition - prior to calling the command line Eiffel compiler.

View File

@@ -1,5 +1,6 @@
[[Property:title|The Eiffel CodeDom Provider]]
[[Property:weight|0]]
[[Property:uuid|0b45f31f-83ea-6301-9017-7b78c6827772]]
The Eiffel CodeDom Provider provides an implementation of the CodeDom Provider generation and compilation interfaces defined in the System.CodeDom namespace of the .NET Framework. This documentation includes the following sections:
* [[About the Code Document Object Model (CodeDom)|About CodeDom]] introduces the basic concepts behing the CodeDom technology.
* [[Installation|Installation]] describes the steps involved in installing the Eiffel CodeDom Provider.

View File

@@ -1,5 +1,6 @@
[[Property:title|Installation]]
[[Property:weight|1]]
[[Property:uuid|b6197932-4bcb-c79b-afe2-1a8f36dbbd7c]]
For certain tools (including ASP.NET) to detect the availability of a CodeDom Provider, the corresponding assembly name must be listed in the .NET machine wide configuration file typically located in:
<code>%SYSTEM_DRIVE%\Windows\Microsoft.NET\Framework\vx.x.xxxx\CONFIG\machine.config</code>
(where vx.x.xxxx corresponds to the .NET Framework version number). The available CodeDom Providers are listed under the ''<compilers>'' XML node. The Eiffel CodeDom Provider implements a.NET Installer class so that should you need to add the Eiffel CodeDom Provider to the machine configuration file, simply run the .NET SDK command line utility ''InstallUtil'' as follows:

View File

@@ -1,5 +1,6 @@
[[Property:title|Logging]]
[[Property:weight|4]]
[[Property:uuid|d425684b-687c-aee6-25fa-650e5885e014]]
The Eiffel CodeDom Provider may be configured (via the [[Eiffel CodeDom Provider Manager|Eiffel Codedom Provider Manager]] ) to log information, warnings and/or errors in the Windows Event Log. Logging may be useful for a number of reasons, some of them are:
* To detect which CodeDom interface method is called and when it's called. This is particularly useful when the source code for the CodeDom consumer (e.g. ASP.NET) is not available.
* To locate the source of a problem when the code generated by the Eiffel CodeDom Provider is incomplete or incorrect. This may happen if the CodeDom tree given to the Eiffel CodeDom Provider uses one of the unsupported constructs as listed in the topic [[Supported Constructs|Supported Constructs]] .

View File

@@ -1,5 +1,6 @@
[[Property:title|Required Permissions]]
[[Property:weight|6]]
[[Property:uuid|f55af6a0-b896-12b7-fe4a-ebb1787731e5]]
The account running the Eiffel CodeDom Provider might have restricted permissions such as when used through ASP.NET. This section aims at defining the security permissions required for the execution of the Eiffel CodeDom Provider.
==Eiffel Metadata Cache==
Both when generating and compiling source code, the Eiffel CodeDom Provider needs to read and write from and to the Eiffel Metadata Cache. This repository stores the mapping information between .NET and Eiffel names for both types and their members. By default the Eiffel Metadata Cache is located in the ''Assemblies'' subfolder of the Eiffel CodeDom Provider directory.

View File

@@ -1,5 +1,6 @@
[[Property:title|CodeDom: Getting Started]]
[[Property:weight|0]]
[[Property:uuid|06e0c7ae-6d25-a0ef-81e6-2ee3c95fe4a1]]
==Prerequesites==
Before you start writing ASP.NET pages in Eiffel, you should be familiar with the ASP.NET technology itself. If you haven't already, it is strongly recommended that you follow the ASP.NET quickstarts available online at [http://samples.gotdotnet.com/quickstart/aspplus/ http://samples.gotdotnet.com/quickstart/aspplus/] . Apart from a few Eiffel specific points described in [[Using Eiffel (to write ASP.NET pages)|Using Eiffel]] , writing ASP.NET pages in Eiffel follows the same rules as writing ASP.NET pages in any other language.
Writing ASP.NET pages in Eiffel also requires to be familiar with the Eiffel language itself. There are no changes in the language when using it to write ASP.NET pages: the same parser and compiler are used to parse and compile standard Eiffel source code and ASP.NET generated source code. Documentation on the Eiffel language can be found on the [http://docs.eiffel.com Eiffel documentation web site] .

View File

@@ -1,5 +1,6 @@
[[Property:title|Eiffel for ASP.NET Installation]]
[[Property:weight|-1]]
[[Property:uuid|c9371a07-12fb-bdb2-b076-3da3c0ec8da6]]
Eiffel for ASP.NET is available for downloading for free at [http://www.eiffel.com http://www.eiffel.com] . Simply run the file and follow the installer instructions. It is recommended that Internet Information Services (IIS) be deployed on the machine prior to installing Eiffel for ASP.NET. If IIS is not deployed then the installation program will display a warning message box. Click '''ignore''' to keep installing the product.
Without IIS, ASP.NET pages cannot be loaded and thus the samples will not be installed. It might still be useful to install Eiffel for ASP.NET without IIS if the Eiffel CodeDom Provider is going to be used through other [[Common Scenarios|scenarios]] . If IIS is available then the installer will open an Eiffel ASP.NET page at the end of the installation process. This page contains links to the documentation and samples. The installer will also put links to these documents in the ''Start'' menu under 'Programs\Eiffel for ASP.NET x.x' where 'x.x' corresponds to the version number of Eiffel for ASP.NET.
==System Requirements==

View File

@@ -1,5 +1,6 @@
[[Property:title|Writing ASP.NET pages in Eiffel]]
[[Property:weight|-1]]
[[Property:uuid|7027e7f3-38e1-5e26-c936-20aea0e0c205]]
Eiffel for ASP.NET allows running ASP.NET pages written in Eiffel. It should be installed on both the web server and the developer's machine. This documentation includes the following sections:
* [[Eiffel for ASP.NET Installation|Installation]] describes the steps involved in installing Eiffel for ASP.NET.
* [[CodeDom: Getting Started|Getting started]] lists resources that will help getting started with Eiffel for ASP.NET.

View File

@@ -1,5 +1,6 @@
[[Property:title|Names Mappings]]
[[Property:weight|4]]
[[Property:uuid|fa212869-ffb0-0a6a-cbd0-7a184b11491d]]
Maybe the most striking difference when writing pages in Eiffel comes from the name of the .NET types and methods. Because of different naming conventions, overloading and differences in identifier validity rules, .NET identifiers cannot be mapped directly to Eiffel identifiers. As a consequence, the Eiffel compiler creates XML mapping files in the ''Eiffel Metadata Cache''. These files are created only once for each referenced assembly.
{{note| '''Note:''' The ASP.NET installation program pre-generates the Eiffel Metadata Cache for all assemblies required by ASP.NET by default. }}
The name mapping algorithm is quite complex but it is possible to guess the Eiffel identifier from the .NET identifier in most cases. The following simple steps can be followed to retrieve the Eiffel identifier corresponding to a .NET type:

View File

@@ -1,5 +1,6 @@
[[Property:title|Using Eiffel (to write ASP.NET pages)]]
[[Property:weight|3]]
[[Property:uuid|c8e2ffa7-cfa8-0b4c-4b5e-e1f386b7ab11]]
==Inheritance==
Eiffel handles inheritance in a different way than most languages. In C# or VB.NET the behavior of a newly introduced member in a class hierarchy is defined as part of the member declaration itself (for example C# will precede the member declaration with the keyword ''override'' to accomplish the same result as an Eiffel ''redefine'' clause). In Eiffel, classes are equipped with an inheritance clause which centralizes all the feature adaptations.
As a result, Eiffel for ASP.NET introduces '''inheritance snippets'''. Each Eiffel ASP.NET page may include at most one inheritance snippet. Such a snippet must start with the '''inherit''' keyword and may then list any valid Eiffel feature adaptation.