This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import inspect | |
import gi | |
from gi.repository import Midgard | |
Midgard.init() | |
for name, obj in inspect.getmembers(Midgard): | |
if inspect.isclass(obj): | |
print(obj.__name__) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from gi.repository import Midgard | |
class RdfMapper: | |
def __init__(self): | |
self.read_types() | |
def read_types(self): | |
for gtype in Midgard.Object.__gtype__.children: | |
self.read_type(gtype) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from gi.repository import Midgard | |
class RdfMapper: | |
def __init__(self, mgd): | |
self.mgd = mgd | |
self.read_types() | |
def read_types(self): | |
for gtype in Midgard.Object.__gtype__.children: | |
self.read_type(gtype) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class GitHubAuth | |
{ | |
const AUTH_URL = 'https://github.com/login/oauth/authorize'; | |
const ACCESS_TOKEN_URL = 'https://github.com/login/oauth/access_token'; | |
private $app_id; | |
private $app_secret; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Mimics ant pattern matching. | |
* New addition (afaict): any pattern ending in '/' will only match directories | |
* @see http://ant.apache.org/manual/dirtasks.html#patterns | |
* @todo more complete testing | |
*/ | |
function pake_antpattern($files, $rootdir) | |
{ | |
$results = array(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data_types: # child-values can be used "as-is" if parent-type is requested | |
"xs:anyType": | |
"xs:untyped": {} | |
"xs:anySimpleType": | |
"xs:anyAtomicType": | |
"xs:untypedAtomic": {} | |
"xs:dateTime": {} | |
"xs:date": {} | |
"xs:time": {} | |
"xs:duration": |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<iframe src="https://www.google.com/calendar/embed?showCalendars=0&showTz=0&mode=AGENDA&height=500&wkst=2&hl=ru&bgcolor=%23FFFFFF&src=9ir9pkisi285laj0buv9r3caug%40group.calendar.google.com&color=%23B1440E&ctz=Europe%2FMoscow" style=" border-width:0 " width="650" height="500" frameborder="0" scrolling="no"></iframe> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CONSTRUCT { | |
?s ?p ?o | |
} | |
where { | |
?s ?p ?o . | |
{ | |
select distinct ?s where {?s [] []} limit 10 | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace GridsBy\SPARQL\GraphStore; | |
use Guzzle\Http\Client; | |
class Connection | |
{ | |
private $endpoint = ''; | |
private $client = null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/************************** | |
* aip variant of php file | |
**************************/ | |
class MyApp | |
{ | |
public function __invoke($context) | |
{ | |
$output = '<h1>Hello world</h1>'; |