Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: fix constraint links #1676

Merged
merged 1 commit into from
Dec 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/constraints/CSharp.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the C# specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For csharp `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/Dart.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the Dart specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For dart `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/Go.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the Go specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For go `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/Java.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the Java specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For java `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/JavaScript.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the JavaScript specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For javascript `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
4 changes: 3 additions & 1 deletion docs/constraints/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ class &name {}
class 1name {}
```

## Customization

There are many rules as such, but to get the full description about the default constraints here:

- [C#](./constraints/CSharp.md)
Expand All @@ -28,7 +30,7 @@ We define these as two types, either you only want to change part of the logic,
- [Overwriting the formatter](../examples/overwrite-naming-formatting) and keep the rest of the constraints as is.
- [Overwriting the entire naming constraint logic](../examples/overwrite-default-constraint) keeping none of the existing functionality which handles edge cases. It is recommended to **NOT** use this if it can be avoided, as you will limit yourself to what inputs can be generated to models. So make sure you know what you are doing :laughing:

# Type mapping
## Type mapping
To make it easier to use the meta models in presets and generators, we need to figure out the types for each model. This is to enable you to access the types from a property rather then calling a function. This is especially relevant because Modelina cannot fit all use-cases out of the box, and we therefore strive to make it tailorable to what ever your needs may be. The type mapping is one of those things that enable you to fine tune the types for your purpose.

Of course it's not all output formats that have a type such as JavaScript, therefore these are only used for strongly typed outputs.
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/Rust.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the Rust specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For Rust `_`, ` ` and `$` are an exception to this rule. |
Expand All @@ -25,7 +25,7 @@ These are the constraints that is applied to object properties and the naming of
|NO_DUPLICATE_PROPERTIES|No duplicate properties|If any of the above constraints changes the property name, we must make sure that no duplicates exist within the same object. If any is encountered `reserved_` is pre-pended. This is done recursively until no duplicates are found.|

## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down
6 changes: 3 additions & 3 deletions docs/constraints/TypeScript.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
These are the TypeScript specific constraints applied to the MetaModel before reaching the presets. [Read here to get a more general idea on the overall process](../input-processing.md) of converting a MetaModel to a ConstrainedMetaModel.

## Model Naming
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to model naming. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand All @@ -14,7 +14,7 @@ These are the constraints that is applied to model naming. The `Rule key` is wha
|NAMING_FORMATTER|Must be formatted equally|Model name is formatted using pascal case|

## Property naming
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to object properties and the naming of them. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).
|Rule key|Rule|Resolution|
|---|---|---|
|NO_SPECIAL_CHAR|No special characters| Special characters are replaced by their name, for example `!` is replaced with `exclamation`. For typescript `_` and `$` are an exception to this rule. |
Expand All @@ -26,7 +26,7 @@ These are the constraints that is applied to object properties and the naming of


## Enum key constraints
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](../constraints.md#Customization).
These are the constraints that is applied to enum keys. The `Rule key` is what you can use in the options to overwrite the default behavior. See [constraint customization](./README.md#Customization).

|Rule key|Rule|Resolution|
|---|---|---|
Expand Down