Skip to content
Open
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
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -115,4 +115,5 @@ gradle-app.setting
# End of https://www.toptal.com/developers/gitignore/api/eclipse,java,gradle

.classpath
*.d.ts
*.d.ts
.idea
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,22 @@ This is a command-line application.
* By default, everything is included
* --exclude: prefixes for excluded paths
* Processed after includes; nothing is excluded by default
* --blacklist: blacklisted type fragments
* Types that have names which contain any of these are omitted
* --blacklist: blacklisted type regular expression patterns
* Types that have names which equals any of these are omitted
* Methods and fields that would use them are also omitted!
* --packageJson: read these options from a JSON file
* The options should be placed under `tsbindOptions` object
* Names of options lack -- prefixes but are otherwise same
* Handy when you already have package.json for publishing
* --index: generate index.d.ts that references other generated files
* --emitReadOnly : if set, deactivates constructors and setter in the generated types
* --excludeMethods : a list of regular expressions that will be used to exclude methods by name
* --groupByModule : if set, the generated types will be grouped by module name, if not set the output will instead be grouped by domain
* --gettersAndSettersOff : if false, Typescript getters and setters will be used to group methods into setters and getters. If true this mechanism is disabled and no intelligence will be performed to regroup getter and setter methods.
* --methodWhitelist : a list of methods using regular expressions that if they match they will be the only methods retained in the generated types
* --flattenTypes : if set the generated types will be flattened, which might that all the inherited methods will be included in the generated types and inheritance will be removed. This makes it possible to reduce the number of types for APIs
* --forceParentJavadocs : if set it will always copy javadocs if they exist on parent types and don't exist locally.
* --debugMatching: if set it will output some useful debug information about the black/white listing mechanism

## Limitations
java-ts-bind does not necessarily generate *valid* TypeScript declarations.
Expand All @@ -44,4 +52,4 @@ Please also note that java-ts-bind provides *only the types*. Implementing
a module loading system for importing them is left as an exercise for the
reader. For pointers, see [CraftJS](https://github.com/Valtakausi/craftjs)
which (at time of writing) implements a CommonJS module loader with
Java and TypeScript.
Java and TypeScript.
3 changes: 1 addition & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,12 @@ repositories {
}

compileJava {
options.release = 16
}

dependencies {
implementation 'com.github.javaparser:javaparser-symbol-solver-core:3.22.1'
implementation 'com.google.code.gson:gson:2.8.6'
implementation 'com.beust:jcommander:1.81'
implementation 'org.jcommander:jcommander:1.83'
implementation 'org.jsoup:jsoup:1.13.1'
}

Expand Down
Loading