Package org.apache.felix.http.base.internal.runtime.dto

# Class ServletDTOBuilder

java.lang.Object
org.apache.felix.http.base.internal.runtime.dto.ServletDTOBuilder

public final class ServletDTOBuilder extends Object

## Constructor Summary

Constructors
Constructor
Description
`ServletDTOBuilder()`

## Method Summary

Modifier and Type
Method
Description
`static org.osgi.service.servlet.runtime.dto.ServletDTO`
`build(ServletHandler handler, int reason)`
Build a servlet DTO from a servlet handler
`static org.osgi.service.servlet.runtime.dto.ServletDTO`
`build(ServletInfo info, int reason)`
Build a servlet DTO from a servlet info
`static void`
`fill(org.osgi.service.servlet.runtime.dto.BaseServletDTO dto, ServletHandler handler)`
Fill a servlet DTO from a servlet handler
`static void`
`fill(org.osgi.service.servlet.runtime.dto.BaseServletDTO dto, ServletInfo info)`
Fill a servlet DTO from a servlet info

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### ServletDTOBuilder

public ServletDTOBuilder()

## Method Details

### build

public static org.osgi.service.servlet.runtime.dto.ServletDTO build(ServletHandler handler, int reason)
Build a servlet DTO from a servlet handler

Parameters:
  `handler` - The servlet handler
  `reason` - If reason is -1, a servlet DTO is created, otherwise a failed servlet DTO is returned
Returns:
  A servlet DTO

### build

public static org.osgi.service.servlet.runtime.dto.ServletDTO build(ServletInfo info, int reason)
Build a servlet DTO from a servlet info

Parameters:
  `info` - The servlet info
  `reason` - The reason for the failure or -1 if the servlet was registered successfully
Returns:
  A servlet DTO

### fill

public static void fill(org.osgi.service.servlet.runtime.dto.BaseServletDTO dto, ServletHandler handler)
Fill a servlet DTO from a servlet handler

Parameters:
  `dto` - The base servlet DTO
  `handler` - The servlet handler

### fill

public static void fill(org.osgi.service.servlet.runtime.dto.BaseServletDTO dto, ServletInfo info)
Fill a servlet DTO from a servlet info

Parameters:
  `dto` - The base servlet DTO
  `info` - The servlet info