/** * <p> * The builder used to create the custom platform. * </p> * * @param builder * The builder used to create the custom platform. * @return Returns a reference to this object so that method calls can be chained together. */ public CreatePlatformVersionResult withBuilder(Builder builder) { setBuilder(builder); return this; }
public CreatePlatformVersionResult unmarshall(StaxUnmarshallerContext context) throws Exception { CreatePlatformVersionResult createPlatformVersionResult = new CreatePlatformVersionResult(); int originalDepth = context.getCurrentDepth(); int targetDepth = originalDepth + 1; if (context.isStartOfDocument()) targetDepth += 2; while (true) { XMLEvent xmlEvent = context.nextEvent(); if (xmlEvent.isEndDocument()) return createPlatformVersionResult; if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) { if (context.testExpression("PlatformSummary", targetDepth)) { createPlatformVersionResult.setPlatformSummary(PlatformSummaryStaxUnmarshaller.getInstance().unmarshall(context)); continue; } if (context.testExpression("Builder", targetDepth)) { createPlatformVersionResult.setBuilder(BuilderStaxUnmarshaller.getInstance().unmarshall(context)); continue; } } else if (xmlEvent.isEndElement()) { if (context.getCurrentDepth() < originalDepth) { return createPlatformVersionResult; } } } }
/** * <p> * The builder used to create the custom platform. * </p> * * @param builder * The builder used to create the custom platform. * @return Returns a reference to this object so that method calls can be chained together. */ public CreatePlatformVersionResult withBuilder(Builder builder) { setBuilder(builder); return this; }
public CreatePlatformVersionResult unmarshall(StaxUnmarshallerContext context) throws Exception { CreatePlatformVersionResult createPlatformVersionResult = new CreatePlatformVersionResult(); int originalDepth = context.getCurrentDepth(); int targetDepth = originalDepth + 1; if (context.isStartOfDocument()) targetDepth += 2; while (true) { XMLEvent xmlEvent = context.nextEvent(); if (xmlEvent.isEndDocument()) return createPlatformVersionResult; if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) { if (context.testExpression("PlatformSummary", targetDepth)) { createPlatformVersionResult.setPlatformSummary(PlatformSummaryStaxUnmarshaller.getInstance().unmarshall(context)); continue; } if (context.testExpression("Builder", targetDepth)) { createPlatformVersionResult.setBuilder(BuilderStaxUnmarshaller.getInstance().unmarshall(context)); continue; } } else if (xmlEvent.isEndElement()) { if (context.getCurrentDepth() < originalDepth) { return createPlatformVersionResult; } } } }