Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Interface {
}

String getInterfaceName() {
Identifier.toClass (name) + "Api"
!name.isEmpty () ? Identifier.toClass (name) + "Api" : "Api"
}

String toString () {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,12 @@ class ApiWriter {

Formatter formatter

ApiWriter (ApiOptions options,
InterfaceWriter interfaceWriter,
DataTypeWriter dataTypeWriter,
StringEnumWriter enumWriter,
boolean enableFormatter = true) {
ApiWriter (
ApiOptions options,
InterfaceWriter interfaceWriter,
DataTypeWriter dataTypeWriter,
StringEnumWriter enumWriter,
boolean enableFormatter = true) {
this.options = options
this.interfaceWriter = interfaceWriter
this.dataTypeWriter = dataTypeWriter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import com.github.hauner.openapi.spring.model.EndpointResponse
import com.github.hauner.openapi.spring.model.RequestBody
import com.github.hauner.openapi.spring.model.parameters.Parameter
import com.github.hauner.openapi.support.Identifier
import com.github.hauner.openapi.support.IdentifierKt

/**
* Writer for Java interface methods, i.e. endpoints.
Expand Down Expand Up @@ -106,7 +105,7 @@ class MethodWriter {

private String createMethodName (Endpoint endpoint, EndpointResponse endpointResponse) {
if (endpoint.operationId != null) {
return IdentifierKt.toCamelCase (endpoint.operationId)
return Identifier.toCamelCase (endpoint.operationId)
}

def tokens = endpoint.path.tokenize ('/')
Expand Down
141 changes: 0 additions & 141 deletions src/main/groovy/com/github/hauner/openapi/support/Identifier.groovy

This file was deleted.

Loading