The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,343 other followers

Archive for April 26th, 2016

O RLY Parody Book Generator for Slack

Posted by jpluimers on 2016/04/26

Oh yes, someone finally did it!

Insult your co-workers with snarky O RLY parody book covers!

Source:

via: O RLY Cover Generator: Create parodies of the iconic O’Reilly book covers

URL example:

https://orly-appstore.herokuapp.com/generate?title=Finding%20your%20own%20G%2B%20posts%20on%20Google&top_text=Your%20off-line%20memory%20organised.&author=Kanye%20West&image_code=13&theme=12

–jeroen

Posted in Development, Software Development | Leave a Comment »

XSD enumerations: key value pairs

Posted by jpluimers on 2016/04/26

One of the things you cannot do in XSD, is have string enumerations contain both a key and a value.

But there is a little appinfo trick inside annotation that you can user under some circumstances, for instance when you interpret the XSD:

<xs:simpleType name="event_result">
<xs:restriction base="xs:string">
<xs:enumeration value="101">
<xsd:annotation><xsd:appinfo>Syntax error</xsd:appinfo></xsd:annotation>
</xs:enumeration>
<xs:enumeration value="102">
<xsd:annotation><xsd:appinfo>Illegal operation</xsd:appinfo></xsd:annotation>
</xs:enumeration>
<xs:enumeration value="103">
<xsd:annotation><xsd:appinfo>Service not available</xsd:appinfo></xsd:annotation>
</xs:enumeration>
</xs:restriction>
</xs:simpleType>

appinfo is the application counterpart of documentation: both can contain any xml, but appinfo is aimed at machines, whereas documentation is aimed at humans.

–jeroen

via:

Posted in Development, Software Development, XML, XML/XSD, XSD | Leave a Comment »

 
%d bloggers like this: