Skip to content

Instantly share code, notes, and snippets.

Pavel Vlasov pvlasov

Block or report user

Report or block pvlasov

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
pvlasov /
Last active Jul 18, 2019
Headless generation of diagram images from Sirius representations (.aird) with image maps
pvlasov / constraint.ecore
Created Apr 23, 2019
Ecore constraint annotation for generation of validation methods
View constraint.ecore
<eAnnotations source="">
<details key="constraints" value="nonNegativeBalance"/>
pvlasov / clear-targets.bat
Created Jan 8, 2019
Recursively remove target directories in multiple Maven projects
View clear-targets.bat
for /f %i in ('dir /a:d /s /b target') do rd /s /q %i
pvlasov /
Created Jan 7, 2019
Demonstrates how to create an EMF resource loading/storing (configuration) model from/to YAML files. It can be used for creating configuration editors for Spring applications, e.g. microservices.
// --- Resource ---
public class YamlResourceImpl extends ResourceImpl {
private Map<String, Object> data;
public YamlResourceImpl(URI uri) {
pvlasov /
Created Jan 6, 2019
Collecting and instantiating concrete subclasses of a specified base class. Can be used to collect children for a reference in emf-based editor
* Iterates over registered ecore packages. Collects and instantiates concrete subclasses.
* @return
public static List<MyType> collectMyTypes() {
List<MyType> ret = new ArrayList<>();
IExtensionRegistry registry = RegistryFactory.getRegistry();
if (registry != null) {
IConfigurationElement[] configElems = registry.getConfigurationElementsFor("org.eclipse.emf.ecore.generated_package");
for (IConfigurationElement elem : configElems) {
pvlasov / mirror-oxygen.bat
Created Jan 26, 2018
Mirroring of Eclipse repos
View mirror-oxygen.bat
eclipsec.exe -application org.eclipse.equinox.p2.metadata.repository.mirrorApplication -source -destination C:\oxygen-repository
eclipsec.exe -application org.eclipse.equinox.p2.artifact.repository.mirrorApplication -source -destination C:\oxygen-repository
pvlasov /
Last active Oct 1, 2017
CDO EMF model annotations
View jsTree context menu on other page elements
$("<element selector>").contextmenu(function(e) {
var jsTree = $('<jstree selector>').jstree();
var obj = jsTree.get_node(<node id>);
jsTree.show_contextmenu(obj, e.pageX, e.pageY, e);
return false;
pvlasov /
Created May 10, 2017
Call graph visualization with Gephi
- Java Call Graph -
- Gexf4j - (download all dependencies with mvn dependency:copy-dependencies)
pvlasov /
Last active Mar 2, 2018
Setting MantisBT behind Apache with NTML

This is a hack. Unfortunately I could not find a description of how to put MantisBT behind Apache with NTLM auth.

Set authentication to BASIC_AUTH in config/config_inc.php:

$g_login_method           = BASIC_AUTH;

core/authentication_api.php - comment out lines 289-291 to disable password check:

You can’t perform that action at this time.