Package org.apache.james.mime4j.field
Class ContentLengthFieldImpl
- java.lang.Object
-
- org.apache.james.mime4j.field.AbstractField
-
- org.apache.james.mime4j.field.ContentLengthFieldImpl
-
- All Implemented Interfaces:
ContentLengthField
,ParsedField
,Field
public class ContentLengthFieldImpl extends AbstractField implements ContentLengthField
Represents aContent-Length
field.
-
-
Field Summary
Fields Modifier and Type Field Description private long
contentLength
private boolean
parsed
static FieldParser<ContentLengthField>
PARSER
-
Fields inherited from class org.apache.james.mime4j.field.AbstractField
monitor, rawField
-
-
Constructor Summary
Constructors Constructor Description ContentLengthFieldImpl(Field rawField, DecodeMonitor monitor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getContentLength()
Gets the content length value defined in this field.private void
parse()
-
Methods inherited from class org.apache.james.mime4j.field.AbstractField
getBody, getName, getNameLowerCase, getParseException, getRaw, getRawField, isValidField, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.james.mime4j.dom.field.ContentLengthField
bodyDescriptionField
-
Methods inherited from interface org.apache.james.mime4j.stream.Field
getBody, getName, getNameLowerCase, getRaw
-
Methods inherited from interface org.apache.james.mime4j.dom.field.ParsedField
getParseException, isValidField
-
-
-
-
Field Detail
-
parsed
private boolean parsed
-
contentLength
private long contentLength
-
PARSER
public static final FieldParser<ContentLengthField> PARSER
-
-
Constructor Detail
-
ContentLengthFieldImpl
ContentLengthFieldImpl(Field rawField, DecodeMonitor monitor)
-
-
Method Detail
-
parse
private void parse()
-
getContentLength
public long getContentLength()
Description copied from interface:ContentLengthField
Gets the content length value defined in this field.- Specified by:
getContentLength
in interfaceContentLengthField
- Returns:
- the content length value.
-
-