-
-
Notifications
You must be signed in to change notification settings - Fork 371
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
🚀 Add event values to events in docs #5690
Conversation
- Added EventValueInfo#getTime() - Added EventValueInfo#isEventExcluded(Class) - Overloaded EventValueInfo instructor and deprecated the old one due to `time` param - Added EventValues#getPerEventEventValues() for getting all events values per event -- useful for docs
@@ -68,6 +75,7 @@ public class HTMLGenerator { | |||
private final File template; | |||
private final File output; | |||
private final String skeleton; | |||
private Map<Class<? extends Event>, List<EventValues.EventValueInfo<?, ?>>> eventValuesCache = new HashMap<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could probably use a MultiMap here
|
||
/** | ||
* Whether the provided event is one of the excluded events of this {@link EventValueInfo} | ||
* @return Either {@link #TIME_PAST}, {@link #TIME_NOW} or {@link #TIME_FUTURE} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think this return javadoc is wrong ;)
prefix = "past "; | ||
else if (eventValueInfo.getTime() == EventValues.TIME_FUTURE) | ||
prefix = "future "; | ||
String className = eventValueInfo.c.getSimpleName().toLowerCase(Locale.ENGLISH); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this use the ClassInfo name instead of replacing?
Co-authored-by: Patrick Miller <[email protected]>
@@ -68,6 +75,7 @@ public class HTMLGenerator { | |||
private final File template; | |||
private final File output; | |||
private final String skeleton; | |||
private Map<Class<? extends Event>, List<EventValues.EventValueInfo<?, ?>>> eventValuesCache = new HashMap<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should clear this cache after the templates have been generated, we don't need it sitting in here.
bd134d0
to
3f08853
Compare
Co-authored-by: LimeGlass <[email protected]>
Co-authored-by: LimeGlass <[email protected]>
closing due to inactivity |
Description
EventValueInfo#getTime()
EventValueInfo#isEventExcluded(Class)
EventValueInfo
constructor and deprecated the old one due totime
paramEventValues#getPerEventEventValues()
for getting all events values per event -- useful for docsPreview
nvm about the broken if condition, that's from my side
Target Minecraft Versions:
Requirements:
Related Issues: