[COTDC] 62 - MIMEType

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

[COTDC] 62 - MIMEType

laurent laffont
Today: MIMEType


Comment Of The Day Contest - One Day One Comment
Rules: 
#1: Each day a not commented class is elected. Each day the best comment will be integrated with name of the author(s).
#2: If you cannot comment it, deprecate it.
Laurent
Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

laurent laffont

On Tue, May 10, 2011 at 8:31 PM, laurent laffont <[hidden email]> wrote:
Today: MIMEType


I guess and represent the content type of a file. For a description of what is MIME, see

Examples:

MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.

MIMEType fromMIMEString: 'application/zip'.


Laurent.



Comment Of The Day Contest - One Day One Comment
Rules: 
#1: Each day a not commented class is elected. Each day the best comment will be integrated with name of the author(s).
#2: If you cannot comment it, deprecate it.
Laurent

Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

Sven Van Caekenberghe

On 12 May 2011, at 20:35, laurent laffont wrote:

> I guess and represent the content type of a file. For a description of what is MIME, see
> http://en.wikipedia.org/wiki/Internet_media_type
> http://en.wikipedia.org/wiki/MIME
>
> Examples:
>
> MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.
>
> MIMEType fromMIMEString: 'application/zip'.

However, MIMEType does not properly deal with extra parameters, as in 'text/plain;charset=utf-8'.
It also does not 'know' very much.
That is why there is a ZnMimeType.

Sven
Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

laurent laffont
On Thu, May 12, 2011 at 9:10 PM, Sven Van Caekenberghe <[hidden email]> wrote:

On 12 May 2011, at 20:35, laurent laffont wrote:

> I guess and represent the content type of a file. For a description of what is MIME, see
> http://en.wikipedia.org/wiki/Internet_media_type
> http://en.wikipedia.org/wiki/MIME
>
> Examples:
>
> MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.
>
> MIMEType fromMIMEString: 'application/zip'.

However, MIMEType does not properly deal with extra parameters, as in 'text/plain;charset=utf-8'.
It also does not 'know' very much.
That is why there is a ZnMimeType.


So now that Zn is in Core, may be we should deprecate MIMEType ?

Laurent.

 

Sven

Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

Stéphane Ducasse
In reply to this post by Sven Van Caekenberghe
may be we should deprecate MIMEType then.
Since now Zinc is in :)


>> I guess and represent the content type of a file. For a description of what is MIME, see
>> http://en.wikipedia.org/wiki/Internet_media_type
>> http://en.wikipedia.org/wiki/MIME
>>
>> Examples:
>>
>> MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.
>>
>> MIMEType fromMIMEString: 'application/zip'.
>
> However, MIMEType does not properly deal with extra parameters, as in 'text/plain;charset=utf-8'.
> It also does not 'know' very much.
> That is why there is a ZnMimeType.
>
> Sven


Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

laurent laffont

On Thu, May 12, 2011 at 9:23 PM, Stéphane Ducasse <[hidden email]> wrote:
may be we should deprecate MIMEType then.
Since now Zinc is in :)



And ZnMime Type is commented ! 

Laurent.
 

>> I guess and represent the content type of a file. For a description of what is MIME, see
>> http://en.wikipedia.org/wiki/Internet_media_type
>> http://en.wikipedia.org/wiki/MIME
>>
>> Examples:
>>
>> MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.
>>
>> MIMEType fromMIMEString: 'application/zip'.
>
> However, MIMEType does not properly deal with extra parameters, as in 'text/plain;charset=utf-8'.
> It also does not 'know' very much.
> That is why there is a ZnMimeType.
>
> Sven



Reply | Threaded
Open this post in threaded view
|

Re: [COTDC] 62 - MIMEType

Stéphane Ducasse
In reply to this post by laurent laffont
Yes!

Stef

On May 12, 2011, at 9:23 PM, laurent laffont wrote:

> On Thu, May 12, 2011 at 9:10 PM, Sven Van Caekenberghe <[hidden email]> wrote:
>
> On 12 May 2011, at 20:35, laurent laffont wrote:
>
>> I guess and represent the content type of a file. For a description of what is MIME, see
>> http://en.wikipedia.org/wiki/Internet_media_type
>> http://en.wikipedia.org/wiki/MIME
>>
>> Examples:
>>
>> MIMEType forFileNameReturnMimeTypesOrDefault: 'index.html'.
>>
>> MIMEType fromMIMEString: 'application/zip'.
>
> However, MIMEType does not properly deal with extra parameters, as in 'text/plain;charset=utf-8'.
> It also does not 'know' very much.
> That is why there is a ZnMimeType.
>
>
> So now that Zn is in Core, may be we should deprecate MIMEType ?
>
> Laurent.
>
>
>
> Sven
>