StringConstantExpression

What it is

StringConstantExpression is used to create a Constant of the type String. A Constant is assigned when it is defined and can not be assigned during a session. The way it is used in the AI-Framework is by assigning a value in the code (so-called hard-coded), which will be translated into a StringConstantExpression by the AI-Framework.

Code example

private IEntityCollection<ArticleEntity> ArticlesToBeDeleted
{
    get 
    { 
        return Property(() => 
            Article.Select<ArticleEntity>
            (AutoLoad.Off).Where(a => 
            a.ArticleNr.Matches("IG*", false, true))); 
    }
}

Explanation of the example

This is the definition of an Entity, based on ArticleEntity, with the name ArticlesToBeDeleted.
In it is a selection, where the ArticleNr must match a String Constant, in this example "IG*".

So ArticlesToBeDeleted is a subset of ArticleEntity. The subset contains the records where ArticleNr starts with IG.