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
[DBus (name = "org.opendcs.Dcs.Extension")] | |
public class Dcs.UI.Extension.DOM : GLib.Object { | |
private int count; | |
private WebKit.WebPage page; | |
private static const JSCore.StaticFunction[] class_functions = {{ | |
"get", (JSCore.ObjectCallAsFunctionCallback) meas_get_cb, JSCore.PropertyAttribute.ReadOnly | |
},{ |
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
# | |
# Procedure : createConfigXML | |
# Arguments : -mdf <filename> Name of mdf file | |
# -ddb <filename> Name of ddb file: exactly one of -mdf or -ddb must be specified | |
# -out <filename> Name of xml file to be generated | |
# -sp Use single precision Delft3D-FLOW executable | |
# -wait "true"/"false" [optional] DelftOnline wait value | |
# Return value: "" : No error | |
# Any other string: Error message | |
# Result : Produces an XML-file (name specified by -out) that can be read by d_hydro.exe (Delft3D-FLOW version 6.xx) |
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
const Obj = ` | |
type Obj { | |
id: String! | |
type: String | |
namespace: String | |
objects: [Obj] | |
properties: [Property] | |
} | |
` |
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
const Property = ` | |
type Property { | |
key: String! | |
value: String | |
} | |
` | |
export default Property |
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
const Plugin = ` | |
type Plugin { | |
id: String! | |
type: String | |
objects: [Obj] | |
properties: [Property] | |
} | |
` | |
export default Plugin |
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 Obj from './object' | |
import Property from './property' | |
import Plugin from './plugin' | |
const Configuration = ` | |
type Configuration { | |
id: String!, | |
properties: [Property] | |
plugins: [Plugin] | |
objects: [Obj] |
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 { makeExecutableSchema } from 'graphql-tools' | |
import Configuration from './configuration' | |
import resolvers from '../resolvers' | |
const Query = ` | |
type Query { | |
configuration(id: String!): Configuration | |
configurations: [Configuration] | |
} |
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
#!/bin/bash | |
sudo dnf -y install https://dl.folkswithhats.org/fedora/$(rpm -E %fedora)/RPMS/fedy-release.rpm | |
sudo dnf -y install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm | |
sudo dnf -y install fedy | |
cd /tmp | |
git clone https://github.com/coanda/dactl.plugin | |
git clone https://github.com/coanda/dactl-mcc.plugin | |
sudo cp -R dactl.plugin /usr/share/fedy/plugins/ | |
sudo cp -R dactl-mcc.plugin /usr/share/fedy/plugins/ |
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
pub fn recv(&mut self) -> Result<Vec<Vec<u8>>, Box<Error>> { | |
let poller = self.poller.as_mut().unwrap(); | |
let sock = poller.wait::<ZSock>(Some(self.timeout.as_millis() as u32)); | |
let mut resp: Vec<Vec<u8>> = Vec::new(); | |
match sock { | |
Some(mut sock) => { | |
let msg = ZMsg::recv::<ZSock>(&mut sock).unwrap(); | |
sock.flush(); |
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
/** | |
* compile: | |
* gcc -g -o json-hashtable `pkg-config --cflags --libs json-glib-1.0` json-hashtable.c | |
* | |
* memcheck: | |
* G_SLICE=always-malloc G_DEBUG=gc-friendly valgrind --tool=memcheck \ | |
* --leak-check=full --show-leak-kinds=definite --errors-for-leak-kinds=definite \ | |
* --leak-resolution=high --num-callers=20 \ | |
* --suppressions=/usr/share/glib-2.0/valgrind/glib.supp \ | |
* ./json-hashtable |
OlderNewer