On Tue, Mar 6, 2018 at 11:01 PM, Apache wrote:
> But I would expect getContentType to return a mime type, not a charset.
>
A content type can contain a charset parameter, for example:
Content-type: text/plain; charset=us-ascii
See
But I would expect getContentType to return a mime type, not a charset.
Ralph
> On Mar 6, 2018, at 9:17 PM, Gary Gregory wrote:
>
>> On Tue, Mar 6, 2018 at 6:01 PM, Remko Popma wrote:
>>
>> Sorry, I don’t follow.
>> Why not get the appender’s
On Tue, Mar 6, 2018 at 6:01 PM, Remko Popma wrote:
> Sorry, I don’t follow.
> Why not get the appender’s layout and get the charset by calling
> getCharset()?
>
Right now, I have this ugly non-OO code:
final Layout layout =
appender.getLayout();
Sorry, I don’t follow.
Why not get the appender’s layout and get the charset by calling getCharset()?
> On Mar 7, 2018, at 7:21, Gary Gregory wrote:
>
> Here is my current use case: I'd like to be able to query getContentType()
> on an FILE appender (File,
Right. AbstractStringLayout says:
@Override
public Charset getCharset() {
return charset;
}
/**
* @return The default content type for Strings.
*/
@Override
public String getContentType() {
return "text/plain";
}
Gary
On Tue, Mar 6, 2018
> On Mar 7, 2018, at 1:37, Gary Gregory <garydgreg...@gmail.com> wrote:
>
> Hi All,
>
> It looks
> like
> org.apache.logging.log4j.core.layout.AbstractStringLayout.getContentType()
> does NOT use its charset.
>
> Can anyone foresee a problem with fixing this?
>
> Gary
Hi All,
It looks
like org.apache.logging.log4j.core.layout.AbstractStringLayout.getContentType()
does NOT use its charset.
Can anyone foresee a problem with fixing this?
Gary