Rhetos.FloydExtensions 6.0.0

Prefix Reserved
dotnet add package Rhetos.FloydExtensions --version 6.0.0
                    
NuGet\Install-Package Rhetos.FloydExtensions -Version 6.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Rhetos.FloydExtensions" Version="6.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Rhetos.FloydExtensions" Version="6.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Rhetos.FloydExtensions" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Rhetos.FloydExtensions --version 6.0.0
                    
#r "nuget: Rhetos.FloydExtensions, 6.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Rhetos.FloydExtensions@6.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Rhetos.FloydExtensions&version=6.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Rhetos.FloydExtensions&version=6.0.0
                    
Install as a Cake Tool

Rhetos.FloydExtensions

Rhetos.FloydExtensions is a DSL package (a plugin module) for Rhetos development platform. It provides an implementation of generating TypeScript model interfaces from DSL model and provider for structure metadata.

Contents:

  1. Installation and configuration
  2. Usage
  3. How to contribute

See rhetos.org for more information on Rhetos.

Installation and configuration

Installing this package to a Rhetos application:

  1. Add 'Rhetos.FloydExtensions' NuGet package, available at the NuGet.org on-line gallery.
  2. Enable CORS requests from the browser for your application. See Enable CORS in ASP.NET Core for more info.

FloydExtensions plugin adds following claims (every user in the system should have permission for this claim):

  • ClaimResource: 'Floyd.GetStructureMetadata', ClaimRight: 'Execute'
  • ClaimResource: 'Floyd.MyClaims', ClaimRight: 'Read'
  • ClaimResource: 'Floyd.GetStorage', ClaimRight: 'Read'
  • ClaimResource: 'Floyd.SaveStorageItem', ClaimRight: 'Execute'

Usage

Generated TypeScript model is placed in bin folder in RhetosAssets\rhetos-model.ts file. Simply include this file in your project. Here is sample of generated TypesScript model:

export module Common {
    ///
    
    export const PrincipalPermissionKey = 'Common/PrincipalPermission'; //constant that represents a key for retrieving metadata via Common.GetStructureMetadata function
    export interface PrincipalPermission {
        ID?: string;
        PrincipalID: string;
        ClaimID: string;
        IsAuthorized?: boolean;
    }
    
    ///
}

In order to retrieve metadata for specified model (DataStructure) call Common.GetStructureMetadata function providing Key parameter. Function returns an object with Value property which contains JSON metadata like this:

{
  key: 'Common/PrincipalPermission', 
  serviceType: 'Entity',
  properties: {
    'PrincipalID': {
      type: 'Reference', 
      referenceKey: 'Common/Principal', 
      required: true
    }, 
    'ClaimID': {
      type: 'Reference', 
      referenceKey: 'Common/Claim', 
      required: true
    }, 
    'IsAuthorized': {
      type: 'Bool', 
    }
  }
}

How to contribute

Contributions are very welcome. The easiest way is to fork this repo, and then make a pull request from your fork. The first time you make a pull request, you may be asked to sign a Contributor Agreement. For more info see How to Contribute on Rhetos wiki.

Building the source code:

  • Note: This package is already available at the NuGet.org online gallery. You don't need to build it from source in order to use it in your application.
  • To build the package from source, run Clean.bat and Build.bat.
  • For the test script to work, you need to create an empty database and a settings file test\TestApp\rhetos-app.local.settings.json with the database connection string (configuration key "ConnectionStrings:RhetosConnectionString").
  • The build output is a NuGet package in the "Install" subfolder.
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
6.0.0 64 9/4/2025
5.2.0 65 9/3/2025
5.1.0 2,211 3/16/2023
5.0.0 654 3/25/2022
1.0.6 520 10/12/2021
1.0.5 490 7/13/2021