This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface DefaultApi { | |
/** | |
* Find a Business by its owner name and surname. | |
*/ | |
@GET("/business/owner") | |
fun getBusinessByOwner( | |
@retrofit2.http.Query("surname") surname: String | |
@retrofit2.http.Query("name") name: String | |
): Single<List<Business>> | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data class IdToInfoForPhotoUploadSuggestionMapToBusinessReviewMap( | |
// ... | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
implementation "com.yelp.android.apis:mobileapi:13.20191020212515.0" | |
implementation "com.yelp.android.apis:bizapp:13.20191020212515.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface DefaultApi { | |
/** | |
* Find business by ID | |
* Returns a single Business by its ID | |
* @param businessId ID of Business to return (required) | |
*/ | |
@GET("/business/{businessId}") | |
fun getBusinessById( | |
@retrofit2.http.Path("businessId") businessId: Long | |
): Single<Business> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Represents a specific Business on Yelp | |
* @property category Optional category of the business | |
* @property id Unique ID of this Business | |
* @property name Name of this specific Business | |
* @property photoUrls Photo URls for this Business | |
* @property status Status of this Business on Yelp | |
*/ | |
data class Business ( | |
@Json(name = "id") var id: Long, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* A Category used to group businesses on Yelp | |
* @property id Unique ID of the Category | |
* @property name Name of this category | |
*/ | |
data class Category( | |
@Json(name = "id") var id: Long? = null, | |
@Json(name = "name") var name: String? = null | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
preBuild.dependsOn(tasks.getByName(“generateSwagger")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
plugins { | |
id("com.yelp.codegen.plugin") version "<latest_version>" | |
} | |
generateSwagger { | |
platform = "kotlin" | |
packageName = "com.yelp.codegen.samples" | |
inputFile = file("./sample_specs.json") | |
outputDir = file("./src/main/java/") | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"definitions": { | |
"Category": { | |
"description": "A Category used to group businesses", | |
"properties": { | |
"id": { | |
"description": "Unique ID of the Category", | |
"format": "int64", | |
"type": "integer" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC = xelatex | |
SRC_DIR = "." | |
OUT_DIR = "." | |
SRC = $(shell find $(SRC_DIR) -name '*.tex') | |
# Build All | |
build: $(SRC) | |
$(CC) -output-directory=$(OUT_DIR) $< |