specifications

Is there a valid way to wrap a dt and a dd with an HTML element?

≡放荡痞女 提交于 2019-11-28 21:01:49
I wish HTML could do something semantically equivalent to this; <dl class="main-list"> <definitionitem> <dt>Some Thing</dt> <dd>You know it!</dd> <dt>Another Thing</dt> <dd>Word.</dd> </definitionitem> <definitionitem> <dt>Stuff</dt> <dd>Alright!</dd> </definitionitem> </dl> However, since the closest I've come is something I'm not 100% satisfied with the semantics of; <div class="redundant-wrapper"> <dl class="main-list"> <dt>Some Thing</dt> <dd>You know it!</dd> <dt>Another Thing</dt> <dd>Word.</dd> </dl> <dl class="another-main-list"> <dt>Stuff!</dt> <dd>Alright!</dd> </dl> </div> I was

PDF specifications for coders: Adobe or ISO?

与世无争的帅哥 提交于 2019-11-28 20:49:34
问题 I want to code an application that can read and decode a pdf document; now where I'm supposed to get the specs for this fileformat ? The PDF format is standardized from the ISO group but it's not clear to me where is the most reliable source for getting this kind of informations. what is a good source to start with this file format ? 回答1: You can actually use both sources you mentioned; the confusion is historical. Adobe invented PDF and it invented the Acrobat product family to be used

Specification Pattern in Domain Driven Design

坚强是说给别人听的谎言 提交于 2019-11-28 17:05:15
I've been struggling around an DDD related issue with Specifications and I've read much into DDD and specifications and repositories. However, there is an issue if trying to combine all 3 of these without breaking the domain driven design. It boils down to how to apply filters with performance in mind. First a few obvious facts: Repositories to got DataAccess/Infrastructure Layer Domain Models represent Business Logic and go to the Domain layer Data Access Models represent Persistence layer and go to the Persistance/Infrastructure/DataAccess layer Business Logic goes to Domain Layer

HTTP Spec: Proxy-Authorization and Authorization headers

放肆的年华 提交于 2019-11-28 15:31:45
So I'm trying to implement the following scenario: An application is protected by Basic Authentication. Let's say it is hosted on app.com An HTTP proxy, in front of the application, requires authentication as well. It is hosted on proxy.com The user must therefore provide credentials for both the proxy and the application in the same request, thus he has different username/password pairs: one pair to authenticate himself against the application, and another username/password pair to authenticate himself against the proxy. After reading the specs, I'm not really sure on how I should implement

Decode data bytes of GIF87a raster data stream

穿精又带淫゛_ 提交于 2019-11-28 14:10:22
I'm trying to decode the data bytes from a GIF87a raster data stream. I'm unsure of how to read the LZW variable length codes (and how LSB...least significant byte first fits in this). The raster data stream starts as follows (in hex): 06 6b 40 86 70 48 2c 1a 8f 44 4b 44 22 89 58 8e 10 c7 e1 80 06 ->code size of 6 6b ->block byte count of 107 40 ->clear code (2^6) which is 64 in decimal or 40 in hex 86 -> start of actual data GIF87a spec: http://www.w3.org/Graphics/GIF/spec-gif87.txt The raster stream should have indexes that point to the global map (or to a parent in the LZW tree)...but I'm

Is a colon a legal first character in an XML tag name?

放肆的年华 提交于 2019-11-28 14:07:14
According to the W3C XML Recommendation , start tag-names have the definition: STag ::= '<' Name (S Attribute)* S? '>' ..where Name is: Name ::= NameStartChar (NameChar)* NameStartChar ::= ":" | [A-Z] | ... ..(n.b., states that a colon can appear as the first character) suggesting the following is a valid XML document: <?xml version="1.0" ?><:doc></:doc> ..but any parser I try this in shows the colon as a formatting error. Also, under Appendices B (though now a depreciated part of the document) it explicitly states: Characters ':' and '_' are allowed as name-start characters. ..and: <?xml

Python: access class variables via instance

南笙酒味 提交于 2019-11-28 13:19:40
In Python, class variables can be accessed via that class instance: >>> class A(object): ... x = 4 ... >>> a = A() >>> a.x 4 It's easy to show that a.x is really resolved to A.x , not copied to an instance during construction: >>> A.x = 5 >>> a.x 5 Despite the fact that this behavior is well known and widely used, I couldn't find any definitive documentation covering it. The closest I could find in Python docs was the section on classes : class MyClass: """A simple example class""" i = 12345 def f(self): return 'hello world' [snip] ... By definition, all attributes of a class that are function

HTTP URL - allowed characters in parameter names

白昼怎懂夜的黑 提交于 2019-11-28 11:54:15
Is there any formal restriction as to which characters are allowed in URL parameter names? I've been reading RFC3986 ("Uniform Resource Identifier (URI): Generic Syntax") but came to no definitive conclusion. I know there are practical limitations, but would it actually be forbidden to do something like: param with\funny<chars>=some_value as long as I escape it correctly: param%20with%1cfunny%3cchars%3e=some_value There are no restrictions on escaped parameter names in the URI specs. There might be restrictions in the server-side software that you use, though. This is especially true if you

What exactly is the HTML5 <command> tag and what is the browser support

元气小坏坏 提交于 2019-11-28 10:45:27
I've read the HTML5 spec for <command> and found the information on this element very vague. I've tried it out and found that it is not working in Chrome (latest version) and it is working on Safari (even older ones), sorry no FF (don't shoot me please) - Mac only test. I can't understand what is the use of this element or even if I'm using it correctly. I thank you in advance for any clarification about it! It works on Firefox 3.6.13 from Windows by the way. The command element is meant to encapsulate something that you can do. It can be rendered within a menu (since a menu presents items you

Constructor chaining in C++

别等时光非礼了梦想. 提交于 2019-11-28 09:37:29
My understanding of constructor chaining is that , when there are more than one constructors in a class (overloaded constructors) , if one of them tries to call another constructor,then this process is called CONSTRUCTOR CHAINING , which is not supported in C++ . Recently I came across this paragraph while reading online material.... It goes like this ... You may find yourself in the situation where you want to write a member function to re-initialize a class back to default values. Because you probably already have a constructor that does this, you may be tempted to try to call the