| POST | /hotelinventorysnapshot/{SubscriptionId}/{CendynPropertyId} |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class HotelInventorySnapshot
{
public InventorySnapshot inventorySnapshot = null;
public String subscriptionId = null;
public String cendynPropertyId = null;
public InventorySnapshot getInventorySnapshot() { return inventorySnapshot; }
public HotelInventorySnapshot setInventorySnapshot(InventorySnapshot value) { this.inventorySnapshot = value; return this; }
public String getSubscriptionId() { return subscriptionId; }
public HotelInventorySnapshot setSubscriptionId(String value) { this.subscriptionId = value; return this; }
public String getCendynPropertyId() { return cendynPropertyId; }
public HotelInventorySnapshot setCendynPropertyId(String value) { this.cendynPropertyId = value; return this; }
}
public static class InventorySnapshot
{
public String cendynPropertyID = null;
public String hotelCode = null;
public Date inventoryDay = null;
public Integer physicalRooms = null;
public Integer outOfOrder = null;
public Integer definitiveSold = null;
public Integer blockCount = null;
public BigDecimal expectedBlockRevenue = null;
public Integer casinoBlockCount = null;
public BigDecimal expectedCasinoRevenue = null;
public String sourceName = null;
public String sourceID = null;
public ArrayList<InventoryRoom> inventoryRooms = null;
public String getCendynPropertyID() { return cendynPropertyID; }
public InventorySnapshot setCendynPropertyID(String value) { this.cendynPropertyID = value; return this; }
public String getHotelCode() { return hotelCode; }
public InventorySnapshot setHotelCode(String value) { this.hotelCode = value; return this; }
public Date getInventoryDay() { return inventoryDay; }
public InventorySnapshot setInventoryDay(Date value) { this.inventoryDay = value; return this; }
public Integer getPhysicalRooms() { return physicalRooms; }
public InventorySnapshot setPhysicalRooms(Integer value) { this.physicalRooms = value; return this; }
public Integer getOutOfOrder() { return outOfOrder; }
public InventorySnapshot setOutOfOrder(Integer value) { this.outOfOrder = value; return this; }
public Integer getDefinitiveSold() { return definitiveSold; }
public InventorySnapshot setDefinitiveSold(Integer value) { this.definitiveSold = value; return this; }
public Integer getBlockCount() { return blockCount; }
public InventorySnapshot setBlockCount(Integer value) { this.blockCount = value; return this; }
public BigDecimal getExpectedBlockRevenue() { return expectedBlockRevenue; }
public InventorySnapshot setExpectedBlockRevenue(BigDecimal value) { this.expectedBlockRevenue = value; return this; }
public Integer getCasinoBlockCount() { return casinoBlockCount; }
public InventorySnapshot setCasinoBlockCount(Integer value) { this.casinoBlockCount = value; return this; }
public BigDecimal getExpectedCasinoRevenue() { return expectedCasinoRevenue; }
public InventorySnapshot setExpectedCasinoRevenue(BigDecimal value) { this.expectedCasinoRevenue = value; return this; }
public String getSourceName() { return sourceName; }
public InventorySnapshot setSourceName(String value) { this.sourceName = value; return this; }
public String getSourceID() { return sourceID; }
public InventorySnapshot setSourceID(String value) { this.sourceID = value; return this; }
public ArrayList<InventoryRoom> getInventoryRooms() { return inventoryRooms; }
public InventorySnapshot setInventoryRooms(ArrayList<InventoryRoom> value) { this.inventoryRooms = value; return this; }
}
public static class InventoryRoom
{
public String roomType = null;
public Integer physicalRooms = null;
public Integer outOfOrder = null;
public Integer definitiveAvailable = null;
public Integer definitiveSold = null;
public Integer blockCount = null;
public BigDecimal expectedBlockRevenue = null;
public Integer casinoBlockCount = null;
public BigDecimal expectedCasinoRevenue = null;
public String getRoomType() { return roomType; }
public InventoryRoom setRoomType(String value) { this.roomType = value; return this; }
public Integer getPhysicalRooms() { return physicalRooms; }
public InventoryRoom setPhysicalRooms(Integer value) { this.physicalRooms = value; return this; }
public Integer getOutOfOrder() { return outOfOrder; }
public InventoryRoom setOutOfOrder(Integer value) { this.outOfOrder = value; return this; }
public Integer getDefinitiveAvailable() { return definitiveAvailable; }
public InventoryRoom setDefinitiveAvailable(Integer value) { this.definitiveAvailable = value; return this; }
public Integer getDefinitiveSold() { return definitiveSold; }
public InventoryRoom setDefinitiveSold(Integer value) { this.definitiveSold = value; return this; }
public Integer getBlockCount() { return blockCount; }
public InventoryRoom setBlockCount(Integer value) { this.blockCount = value; return this; }
public BigDecimal getExpectedBlockRevenue() { return expectedBlockRevenue; }
public InventoryRoom setExpectedBlockRevenue(BigDecimal value) { this.expectedBlockRevenue = value; return this; }
public Integer getCasinoBlockCount() { return casinoBlockCount; }
public InventoryRoom setCasinoBlockCount(Integer value) { this.casinoBlockCount = value; return this; }
public BigDecimal getExpectedCasinoRevenue() { return expectedCasinoRevenue; }
public InventoryRoom setExpectedCasinoRevenue(BigDecimal value) { this.expectedCasinoRevenue = value; return this; }
}
public static class Response
{
public String statusCode = null;
public Integer recordCount = null;
public Integer errorCount = null;
public String getStatusCode() { return statusCode; }
public Response setStatusCode(String value) { this.statusCode = value; return this; }
public Integer getRecordCount() { return recordCount; }
public Response setRecordCount(Integer value) { this.recordCount = value; return this; }
public Integer getErrorCount() { return errorCount; }
public Response setErrorCount(Integer value) { this.errorCount = value; return this; }
}
}
Java HotelInventorySnapshot DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /hotelinventorysnapshot/{SubscriptionId}/{CendynPropertyId} HTTP/1.1
Host: cert.cendyn.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"inventorySnapshot":{"cendynPropertyID":"String","hotelCode":"String","inventoryDay":"0001-01-01T00:00:00.0000000","physicalRooms":0,"outOfOrder":0,"definitiveSold":0,"blockCount":0,"expectedBlockRevenue":0,"casinoBlockCount":0,"expectedCasinoRevenue":0,"sourceName":"String","sourceID":"String","inventoryRooms":[{"roomType":"String","physicalRooms":0,"outOfOrder":0,"definitiveAvailable":0,"definitiveSold":0,"blockCount":0,"expectedBlockRevenue":0,"casinoBlockCount":0,"expectedCasinoRevenue":0}]},"subscriptionId":"String","cendynPropertyId":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"statusCode":"String","recordCount":0,"errorCount":0}