magic.lambda.xml 17.2.0

dotnet add package magic.lambda.xml --version 17.2.0
NuGet\Install-Package magic.lambda.xml -Version 17.2.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="magic.lambda.xml" Version="17.2.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add magic.lambda.xml --version 17.2.0
#r "nuget: magic.lambda.xml, 17.2.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.
// Install magic.lambda.xml as a Cake Addin
#addin nuget:?package=magic.lambda.xml&version=17.2.0

// Install magic.lambda.xml as a Cake Tool
#tool nuget:?package=magic.lambda.xml&version=17.2.0

magic.lambda.xml - Parsing and creating XML from Hyperlambda

This project provides XML helper slots for Hyperlambda. More specifically, it provides the following slots.

  • [xml2lambda] - Creates a lambda object out of an XML input string
  • [lambda2xml] - Creates an XML string from a lambda object

How to use [xml2lambda]

.xml:@"<CATALOG>
  <PLANT>
    <COMMON>Bloodroot</COMMON>
    <BOTANICAL>Sanguinaria canadensis</BOTANICAL>
    <ZONE>4</ZONE>
    <LIGHT>Mostly Shady</LIGHT>
    <PRICE>$2.44</PRICE>
    <AVAILABILITY>031599</AVAILABILITY>
  </PLANT>
</CATALOG>
"
xml2lambda:x:@.xml

The above results in something resembling the following.

xml2lambda
   CATALOG
      PLANT
         COMMON
            #text:Bloodroot
         BOTANICAL
            #text:Sanguinaria canadensis
         ZONE
            #text:4
         LIGHT
            #text:Mostly Shady
         PRICE
            #text:$2.44
         AVAILABILITY
            #text:031599

Attributes starts out with the @ character, children nodes does not - While text content inside of elements will be named #text. This implies you'll need to use escaped expression iterators when traversing the resulting node lambda object. For instance, to retrieve the above PRICE element's inner text, you could use something such as the following.

get-value:x:@xml2lambda/**/PRICE/*/\#text

How to use [lambda2xml]

To convert from a lambda object to an XML object you can use something such as follows.

.xml
   CATALOG
      PLANT
         COMMON
            #text:Bloodroot
         BOTANICAL
            #text:Sanguinaria canadensis
         ZONE
            #text:4
         LIGHT
            #text:Mostly Shady
         PRICE
            #text:$2.44
         AVAILABILITY
            #text:031599
lambda2xml:x:@.xml/*

Magic's GitHub project page

Magic is 100% Open Source and you can find the primary project GitHub page here.

Project website for magic.lambda.xml

The source code for this repository can be found at github.com/polterguy/magic.lambda.xml, and you can provide feedback, provide bug reports, etc at the same place.

  • Build status
  • Quality Gate Status
  • Bugs
  • Code Smells
  • Coverage
  • Duplicated Lines (%)
  • Lines of Code
  • Maintainability Rating
  • Reliability Rating
  • Security Rating
  • Technical Debt
  • Vulnerabilities

The projects is copyright Thomas Hansen 2023 - 2024, and professionally maintained by AINIRO.IO.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on magic.lambda.xml:

Package Downloads
magic.library

Helper project for Magic to wire up everything easily by simply adding one package, and invoking two simple methods. When using Magic, this is (probably) the only package you should actually add, since this package pulls in everything else you'll need automatically, and wires up everything sanely by default. To use package go to https://polterguy.github.io

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
17.2.0 280 1/22/2024
17.1.7 150 1/12/2024
17.1.6 132 1/11/2024
17.1.5 142 1/5/2024
17.0.1 171 1/1/2024
17.0.0 313 12/14/2023
16.11.5 287 11/12/2023
16.9.0 292 10/9/2023
16.7.0 474 7/11/2023
16.4.1 323 7/2/2023
16.4.0 315 6/22/2023
16.3.1 275 6/7/2023
16.3.0 282 5/28/2023
16.1.9 543 4/30/2023
15.10.11 415 4/13/2023
15.9.1 517 3/27/2023
15.9.0 406 3/24/2023
15.8.2 443 3/20/2023
15.7.0 312 3/6/2023
15.5.1 1,291 2/3/2023
15.5.0 468 1/28/2023
15.2.0 605 1/18/2023
15.1.0 1,089 12/28/2022
14.5.7 661 12/13/2022
14.5.5 771 12/6/2022