-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrated the solution projects to .net standard 1.6 and full .net 4.6.2
- Loading branch information
Showing
6 changed files
with
90 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
using SimpleNLG; | ||
using System; | ||
using System.Collections.Generic; | ||
|
||
namespace SharpSimpleNLGConsoleNetCore | ||
{ | ||
class Program | ||
{ | ||
public static void Main(string[] args) | ||
{ | ||
var ss = new XMLLexicon(); | ||
var Factory = new NLGFactory(ss); | ||
var Realiser = new Realiser(ss); | ||
|
||
// Instructions will be given to you by the director. | ||
|
||
var verbp = Factory.createVerbPhrase("be given"); | ||
verbp.setFeature(Feature.TENSE.ToString(), Tense.FUTURE); | ||
var subj = Factory.createNounPhrase("The Director"); | ||
var oobj = Factory.createNounPhrase("Instruction"); | ||
var ioobj = Factory.createNounPhrase("you"); | ||
subj.setPlural(false); | ||
oobj.setPlural(true); | ||
|
||
var s = new List<INLGElement>() { verbp, subj, oobj, ioobj }; | ||
|
||
var clause = Factory.createClause(); | ||
|
||
clause.setVerb(verbp); | ||
clause.setSubject(subj); | ||
clause.setObject(oobj); | ||
clause.setIndirectObject(ioobj); | ||
|
||
|
||
var sentence = Factory.createSentence(clause); | ||
sentence.setFeature(Feature.TENSE.ToString(), Tense.FUTURE); | ||
|
||
var active = Realiser.realise(sentence).ToString(); | ||
|
||
Console.WriteLine($"{active}"); | ||
|
||
Console.WriteLine("done"); | ||
Console.ReadLine(); | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
SharpSimpleNLGConsoleNetCore/SharpSimpleNLGConsoleNetCore.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<OutputType>Exe</OutputType> | ||
<TargetFramework>netcoreapp1.1</TargetFramework> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\SharpSimpleNLG\SharpSimpleNLG.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<packages> | ||
<package id="FluentAssertions" version="4.9.0" targetFramework="net452" /> | ||
<package id="NUnit" version="3.2.1" targetFramework="net452" /> | ||
<package id="Shouldly" version="2.7.0" targetFramework="net452" /> | ||
<package id="FluentAssertions" version="4.19.3" targetFramework="net462" /> | ||
<package id="NUnit" version="3.7.1" targetFramework="net462" /> | ||
<package id="Shouldly" version="2.8.3" targetFramework="net462" /> | ||
</packages> |