drasil-lang-0.1.60.0: A framework for code and document generation for scientific software - Language SubPackage
Safe HaskellNone
LanguageHaskell2010

Language.Drasil.Chunk.NamedIdea

Description

The lowest level of chunks in Drasil. It all starts with an identifier and a term.

Synopsis

Types

data NamedChunk Source #

Used for anything worth naming. Note that a NamedChunk does not have an acronym/abbreviation as that's a CommonIdea, which has its own representation. Contains a UID and a term that we can capitalize or pluralize (NP).

Ex. Anything worth naming must start out somewhere. Before we can assign equations and values and symbols to something like the arm of a pendulum, we must first give it a name.

Instances

Instances details
Eq NamedChunk Source #

Equal if UIDs are equal.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

HasUID NamedChunk Source #

Finds the UID of the NamedChunk.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

uid :: Lens' NamedChunk UID Source #

Idea NamedChunk Source #

Finds the idea of a NamedChunk (always Nothing).

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

NamedIdea NamedChunk Source #

Finds the term (NP) of the NamedChunk.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

term :: Lens' NamedChunk NP Source #

data IdeaDict Source #

IdeaDict is the canonical dictionary associated to an Idea. Contains a NamedChunk that could have an abbreviation (Maybe String).

Ex. The project name "Double Pendulum" may have the abbreviation DblPendulum.

Instances

Instances details
Eq IdeaDict Source #

Equal if UIDs are equal.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

HasUID IdeaDict Source #

Finds the UID of the NamedChunk used to make the IdeaDict.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

uid :: Lens' IdeaDict UID Source #

Idea IdeaDict Source #

Finds the abbreviation of the IdeaDict.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

NamedIdea IdeaDict Source #

Finds the term (NP) of the NamedChunk used to make the IdeaDict.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

term :: Lens' IdeaDict NP Source #

Classes

class HasUID c => NamedIdea c where Source #

A NamedIdea is a term that we've identified (has a UID) as being worthy of naming.

Methods

term :: Lens' c NP Source #

Lens to the term (a noun phrase).

Instances

Instances details
NamedIdea NamedChunk Source #

Finds the term (NP) of the NamedChunk.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

term :: Lens' NamedChunk NP Source #

NamedIdea IdeaDict Source #

Finds the term (NP) of the NamedChunk used to make the IdeaDict.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Methods

term :: Lens' IdeaDict NP Source #

NamedIdea CI Source #

Finds term (NP) of the NamedChunk used to make the CI.

Instance details

Defined in Language.Drasil.Chunk.CommonIdea

Methods

term :: Lens' CI NP Source #

NamedIdea ConceptChunk Source #

Finds term (NP) of the IdeaDict used to make the ConceptChunk.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Methods

term :: Lens' ConceptChunk NP Source #

NamedIdea CommonConcept Source #

Finds term (NP) of the CI used to make the CommonConcept.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Methods

term :: Lens' CommonConcept NP Source #

NamedIdea ConceptInstance Source #

Finds term (NP) of the ConceptChunk used to make the ConceptInstance.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Methods

term :: Lens' ConceptInstance NP Source #

NamedIdea RelationConcept Source #

Finds the term (NP) of the ConceptChunk used to make the RelationConcept.

Instance details

Defined in Language.Drasil.Chunk.Relation

Methods

term :: Lens' RelationConcept NP Source #

NamedIdea UnitDefn Source #

Finds term (NP) of the ConceptChunk used to make the UnitDefn.

Instance details

Defined in Language.Drasil.Chunk.UnitDefn

Methods

term :: Lens' UnitDefn NP Source #

NamedIdea QuantityDict Source #

Finds the term (NP) of the IdeaDict used to make the QuantityDict.

Instance details

Defined in Language.Drasil.Chunk.Quantity

Methods

term :: Lens' QuantityDict NP Source #

NamedIdea UnitaryChunk Source #

Finds term (NP) of the QuantityDict used to make the UnitaryChunk.

Instance details

Defined in Language.Drasil.Chunk.Unitary

Methods

term :: Lens' UnitaryChunk NP Source #

NamedIdea DefinedQuantityDict Source #

Finds the term (NP) of the ConceptChunk used to make the DefinedQuantityDict.

Instance details

Defined in Language.Drasil.Chunk.DefinedQuantity

NamedIdea UnitalChunk Source #

Finds term (NP) of the DefinedQuantityDict used to make the UnitalChunk.

Instance details

Defined in Language.Drasil.Chunk.Unital

Methods

term :: Lens' UnitalChunk NP Source #

NamedIdea ConstrainedChunk Source #

Finds term (NP) of the QuantityDict used to make the ConstrainedChunk.

Instance details

Defined in Language.Drasil.Chunk.Constrained

Methods

term :: Lens' ConstrainedChunk NP Source #

NamedIdea ConstrConcept Source #

Finds term (NP) of the DefinedQuantityDict used to make the ConstrConcept.

Instance details

Defined in Language.Drasil.Chunk.Constrained

Methods

term :: Lens' ConstrConcept NP Source #

NamedIdea UncertainChunk Source #

Finds term (NP) of the ConstrainedChunk used to make the UncertainChunk.

Instance details

Defined in Language.Drasil.Chunk.UncertainQuantity

Methods

term :: Lens' UncertainChunk NP Source #

NamedIdea UncertQ Source #

Finds term (NP) of the ConstrConcept used to make the UncertQ.

Instance details

Defined in Language.Drasil.Chunk.UncertainQuantity

Methods

term :: Lens' UncertQ NP Source #

NamedIdea DifferentialModel Source #

Finds the term (NP) of the ConceptChunk used to make the DifferentialModel.

Instance details

Defined in Language.Drasil.Chunk.DifferentialModel

Methods

term :: Lens' DifferentialModel NP Source #

NamedIdea (QDefinition e) Source # 
Instance details

Defined in Language.Drasil.Chunk.Eq

Methods

term :: Lens' (QDefinition e) NP Source #

class NamedIdea c => Idea c where Source #

An Idea is the combination of a NamedIdea and a CommonIdea. In other words, it may have an acronym/abbreviation.

Methods

getA :: c -> Maybe String Source #

Gets the acronym/abbreviation.

Instances

Instances details
Idea NamedChunk Source #

Finds the idea of a NamedChunk (always Nothing).

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Idea IdeaDict Source #

Finds the abbreviation of the IdeaDict.

Instance details

Defined in Language.Drasil.Chunk.NamedIdea

Idea CI Source #

Finds the idea of a CI (abbreviation).

Instance details

Defined in Language.Drasil.Chunk.CommonIdea

Methods

getA :: CI -> Maybe String Source #

Idea ConceptChunk Source #

Finds the idea contained in the IdeaDict used to make the ConceptChunk.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Idea CommonConcept Source #

Finds the idea contained in the CI used to make the CommonConcept.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Idea ConceptInstance Source #

Finds the idea contained in the ConceptChunk used to make the ConceptInstance.

Instance details

Defined in Language.Drasil.Chunk.Concept.Core

Idea RelationConcept Source #

Finds the idea contained in the ConceptChunk used to make the RelationConcept.

Instance details

Defined in Language.Drasil.Chunk.Relation

Idea UnitDefn Source #

Finds the idea contained in the ConceptChunk used to make the UnitDefn.

Instance details

Defined in Language.Drasil.Chunk.UnitDefn

Idea QuantityDict Source #

Finds the idea contained in the IdeaDict used to make the QuantityDict.

Instance details

Defined in Language.Drasil.Chunk.Quantity

Idea UnitaryChunk Source #

Finds the idea contained in the QuantityDict used to make the UnitaryChunk.

Instance details

Defined in Language.Drasil.Chunk.Unitary

Idea DefinedQuantityDict Source #

Finds the idea contained in the ConceptChunk used to make the DefinedQuantityDict.

Instance details

Defined in Language.Drasil.Chunk.DefinedQuantity

Idea UnitalChunk Source #

Finds the idea contained in the DefinedQuantityDict used to make the UnitalChunk.

Instance details

Defined in Language.Drasil.Chunk.Unital

Idea ConstrainedChunk Source #

Finds the idea contained in the QuantityDict used to make the ConstrainedChunk.

Instance details

Defined in Language.Drasil.Chunk.Constrained

Idea ConstrConcept Source #

Finds the idea contained in the DefinedQuantityDict used to make the ConstrConcept.

Instance details

Defined in Language.Drasil.Chunk.Constrained

Idea UncertainChunk Source #

Finds the idea contained in the ConstrainedChunk used to make the UncertainChunk.

Instance details

Defined in Language.Drasil.Chunk.UncertainQuantity

Idea UncertQ Source #

Finds the idea contained in the ConstrConcept used to make the UncertQ.

Instance details

Defined in Language.Drasil.Chunk.UncertainQuantity

Idea DifferentialModel Source #

Finds the idea contained in the ConceptChunk used to make the DifferentialModel.

Instance details

Defined in Language.Drasil.Chunk.DifferentialModel

Idea (QDefinition e) Source # 
Instance details

Defined in Language.Drasil.Chunk.Eq

Constructors

nc :: String -> NP -> NamedChunk Source #

NamedChunk constructor, takes a String for its UID and a term.

ncUID :: UID -> NP -> NamedChunk Source #

Similar to nc, but takes in the UID in the form of a UID rather than a String.

nw :: Idea c => c -> IdeaDict Source #

Historical name: nw comes from 'named wrapped' from when NamedIdea exported getA (now in Idea). But there are no more wrappers, instead we have explicit dictionaries. Unwraps an Idea and places its UID and NP into an IdeaDict with Nothing for an abbreviation.

mkIdea :: String -> NP -> Maybe String -> IdeaDict Source #

IdeaDict constructor, takes a UID, NP, and an abbreviation in the form of Maybe String.

mkIdeaUID :: UID -> NP -> Maybe String -> IdeaDict Source #

Same as mkIdea but takes a UID rather than a String.