Conversation
d1f6609 to
c79e583
Compare
17e1c86 to
d6822cc
Compare
…ventions table. Use full words instead of abbreviations.
aep/general/0160/aep.md
Outdated
| | Operator | Meaning | Example | | ||
| |----------------------|---------------------------------------------------------|----------------------------------| | ||
| | (none) | Equals (direct field name) | `status=ACTIVE` | | ||
| | `NotEqual` | Not equals | `statusNotEqual=CANCELLED` | | ||
| | `LessThan` | Strictly less than `<` | `priceLessThan=100` | | ||
| | `LessThanOrEqual` | Less than or equal `< =` | `priceLessThanOrEqual=100` | | ||
| | `GreaterThan` | Strictly greater than `>` | `priceGreaterThan=100` | | ||
| | `GreaterThanOrEqual` | Greater than or equal `> =` | `priceGreaterThanOrEqual=100` | | ||
| | `Maximum` | Upper bound (inclusive) `< =` | `capacityMaximum=500` | | ||
| | `Minimum` | Lower bound (inclusive) `> =` | `capacityMinimum=50` | | ||
| | `Before` | Timestamp strictly before `<` | `createdTimeBefore=2025-01-01` | | ||
| | `Latest` | Timestamp at or before `< =` | `createdTimeLatest=2025-01-01` | | ||
| | `After` | Timestamp strictly after `>` | `createdTimeAfter=2025-01-01` | | ||
| | `Earliest` | Timestamp at or after `> =` | `createdTimeEarliest=2025-01-01` | | ||
| | `has` (prefix) | [Nullability and existence](#nullability-and-existence) | `hasPhoneNumber=true` | |
There was a problem hiding this comment.
it is really confusing to organize this by "operator" because it's not obvious that there are multiple options for the same semantics. Also these aren't even operators, they are suffixes or prefixes. I think it would be much clearer to group by operation.
Additionally the name should read like English grammar. For some this requires using a prefix rather than a suffix. Here is my proposal:
| | Operator | Meaning | Example | | |
| |----------------------|---------------------------------------------------------|----------------------------------| | |
| | (none) | Equals (direct field name) | `status=ACTIVE` | | |
| | `NotEqual` | Not equals | `statusNotEqual=CANCELLED` | | |
| | `LessThan` | Strictly less than `<` | `priceLessThan=100` | | |
| | `LessThanOrEqual` | Less than or equal `< =` | `priceLessThanOrEqual=100` | | |
| | `GreaterThan` | Strictly greater than `>` | `priceGreaterThan=100` | | |
| | `GreaterThanOrEqual` | Greater than or equal `> =` | `priceGreaterThanOrEqual=100` | | |
| | `Maximum` | Upper bound (inclusive) `< =` | `capacityMaximum=500` | | |
| | `Minimum` | Lower bound (inclusive) `> =` | `capacityMinimum=50` | | |
| | `Before` | Timestamp strictly before `<` | `createdTimeBefore=2025-01-01` | | |
| | `Latest` | Timestamp at or before `< =` | `createdTimeLatest=2025-01-01` | | |
| | `After` | Timestamp strictly after `>` | `createdTimeAfter=2025-01-01` | | |
| | `Earliest` | Timestamp at or after `> =` | `createdTimeEarliest=2025-01-01` | | |
| | `has` (prefix) | [Nullability and existence](#nullability-and-existence) | `hasPhoneNumber=true` | | |
| | Filtering operation | Pattern | Example | | |
| |---------------------------------------------------------|-----------------------------|---------------------------------| | |
| | Equals | `{field}` | `status=ACTIVE` | | |
| | Not equals | `{field}NotEqual` | `statusNotEqual=CANCELLED` | | |
| | Lower bound (exclusive) `>` | `{field}GreaterThan` | `priceGreaterThan=100` | | |
| | Lower bound (exclusive) `>` | `{field}After` | `createTimeAfter=2025-01-01` | | |
| | Lower bound (inclusive) `>=` | `{field}GreaterThanOrEqual` | `priceGreaterThanOrEqual=100` | | |
| | Lower bound (inclusive) `>=` | `min{Field}` | `minCapacity=50` | | |
| | Lower bound (inclusive) `>=` | `minimum{Field}` | `minimumCapacity=50` | | |
| | Lower bound (inclusive) `>=` | `earliest{Field}` | `earliestCreateTime=2025-01-01` | | |
| | Upper bound (inclusive) `<=` | `{field}LessThanOrEqual` | `priceLessThanOrEqual=100` | | |
| | Upper bound (inclusive) `<=` | `max{Field}` | `maxCapacity=500` | | |
| | Upper bound (inclusive) `<=` | `maximum{Field}` | `maxiumuCapacity=500` | | |
| | Upper bound (inclusive) `<=` | `latest{Field}` | `latestCreateTime=2025-01-01` | | |
| | Upper bound (exclusive) `<` | `{field}LessThan` | `priceLessThan=100` | | |
| | Upper bound (exclusive) `<` | `{field}Before` | `createTimeBefore=2025-01-01` | | |
| | [Nullability and existence](#nullability-and-existence) | `has{Field}` | `hasPhoneNumber=true` | |
or if <br/> renders correctly:
| | Operator | Meaning | Example | | |
| |----------------------|---------------------------------------------------------|----------------------------------| | |
| | (none) | Equals (direct field name) | `status=ACTIVE` | | |
| | `NotEqual` | Not equals | `statusNotEqual=CANCELLED` | | |
| | `LessThan` | Strictly less than `<` | `priceLessThan=100` | | |
| | `LessThanOrEqual` | Less than or equal `< =` | `priceLessThanOrEqual=100` | | |
| | `GreaterThan` | Strictly greater than `>` | `priceGreaterThan=100` | | |
| | `GreaterThanOrEqual` | Greater than or equal `> =` | `priceGreaterThanOrEqual=100` | | |
| | `Maximum` | Upper bound (inclusive) `< =` | `capacityMaximum=500` | | |
| | `Minimum` | Lower bound (inclusive) `> =` | `capacityMinimum=50` | | |
| | `Before` | Timestamp strictly before `<` | `createdTimeBefore=2025-01-01` | | |
| | `Latest` | Timestamp at or before `< =` | `createdTimeLatest=2025-01-01` | | |
| | `After` | Timestamp strictly after `>` | `createdTimeAfter=2025-01-01` | | |
| | `Earliest` | Timestamp at or after `> =` | `createdTimeEarliest=2025-01-01` | | |
| | `has` (prefix) | [Nullability and existence](#nullability-and-existence) | `hasPhoneNumber=true` | | |
| | Filtering operation | Pattern | Example | | |
| |---------------------------------------------------------|-----------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------| | |
| | Equals | `{field}` | `status=ACTIVE` | | |
| | Not equals | `{field}NotEqual` | `statusNotEqual=CANCELLED` | | |
| | Lower bound (exclusive) `>` | `{field}GreaterThan`<br/>`{field}After` | `priceGreaterThan=100`<br/>`createTimeAfter=2025-01-01` | | |
| | Lower bound (inclusive) `>=` | `{field}GreaterThanOrEqual`<br/>`min{Field}`<br/>`minimum{Field}`<br/>`earliest{Field}` | `priceGreaterThanOrEqual=100`<br/>`minCapacity=50`<br/>`minimumCapacity=50`<br/>`earliestCreateTime=2025-01-01` | | |
| | Upper bound (inclusive) `<=` | `{field}LessThanOrEqual`<br/>`max{Field}`<br/>`maximum{Field}`<br/>`latest{Field}` | `priceLessThanOrEqual=100`<br/>`maxCapacity=500`<br/>`maxiumuCapacity=500`<br/>`latestCreateTime=2025-01-01` | | |
| | Upper bound (exclusive) `<` | `{field}LessThan`<br/>`{field}Before` | `priceLessThan=100`<br/>`createTimeBefore=2025-01-01` | | |
| | [Nullability and existence](#nullability-and-existence) | `has{Field}` | `hasPhoneNumber=true` | |
There was a problem hiding this comment.
Ah, I see what you are going for, yeah, that looks good.
I changed minimum, maximum, earliest and latest to be prefixes.
I still think the timestamp specific fields should be separate rows though. To make it clear that after, before, earliest, and latest are to be used with timestamps specifically. So I kept those separate still, but merged the other rows like your suggestion.
Change format from underscore (
_) tocamelCase. Add to naming conventions table. Use full words instead of abbreviations.