Skip to content

Instantly share code, notes, and snippets.

Avatar

Dmitry Osin dmitry-osin

View GitHub Profile
@dmitry-osin
dmitry-osin / emoji.md
Created Dec 22, 2020 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup
View emoji.md

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
View XPathUtils.java
@UtilityClass
public class XPathUtils {
public Map<String, Object> extractValue(@NonNull String json, @NonNull String xPath) {
Map<String, Object> jsonValue = U.fromXmlMap(json);
return extractValue(jsonValue, xPath);
}
@SuppressWarnings("unchecked")
public Map<String, Object> extractValue(@NonNull Map<String, Object> jsonMap, @NonNull String xPath) {
@dmitry-osin
dmitry-osin / .bash_profile
Created Oct 8, 2019 — forked from natelandau/.bash_profile
Mac OSX Bash Profile
View .bash_profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
View GenericRepository.cs
using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Data.Entity.Migrations;
using System.Linq;
using System.Linq.Expressions;
using Shortener.Web.Contracts;
using Shortener.Web.Infrastructure;
namespace Shortener.Web.Repository
View gist:b14fe098909bb4f84fd9f2b1a8252325
package com.wiley.gts.bce.common.util.xml.impl;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.UUID;
import java.util.regex.Matcher;
import java.util.stream.Collectors;
View XPath
<bean id="xpathExpressionNotes" class="org.springframework.xml.xpath.XPathExpressionFactoryBean"
p:expression="/w:component/w:header/w:contentMeta/w:noteGroup//w:note[contains(.,'(primary)')]"
p:namespaces-ref="bceNamespacesMap"/>
View NCBI-Sample.xml
<?xml version="1.0" encoding="UTF-8"?>
<root>
<taxonomy name="NCBI">
<term externalId="NCBI-131567">
<synonym uniqueName="Bacteria &lt;prokaryotes&gt;">Bacteria</synonym>
<synonym uniqueName="Monera &lt;Bacteria&gt;">Monera</synonym>
<synonym uniqueName="Procaryotae &lt;Bacteria&gt;">Procaryotae</synonym>
<synonym uniqueName="Prokaryota &lt;Bacteria&gt;">Prokaryota</synonym>
<synonym uniqueName="Prokaryotae &lt;Bacteria&gt;">Prokaryotae</synonym>
<synonym uniqueName="bacteria &lt;blast2&gt;">bacteria</synonym>
View gist:cceeaeffa52cbb461abdb2c8292588c6
<?xml version="1.0" encoding="UTF-8" standalone="no"?><root><taxonomy name="NCBI"><term externalId="NCBI-131567"><synonym uniqueName="Bacteria &lt;prokaryotes&gt;">Bacteria</synonym><synonym uniqueName="Monera &lt;Bacteria&gt;">Monera</synonym><synonym uniqueName="Procaryotae &lt;Bacteria&gt;">Procaryotae</synonym><synonym uniqueName="Prokaryota &lt;Bacteria&gt;">Prokaryota</synonym><synonym uniqueName="Prokaryotae &lt;Bacteria&gt;">Prokaryotae</synonym><synonym uniqueName="bacteria &lt;blast2&gt;">bacteria</synonym><synonym uniqueName="">eubacteria</synonym><synonym uniqueName="prokaryote &lt;Bacteria&gt;">prokaryote</synonym><synonym uniqueName="prokaryotes &lt;Bacteria&gt;">prokaryotes</synonym></term><term externalId="NCBI-335928"><synonym uniqueName="">Azorhizobium</synonym><synonym uniqueName="">Azorhizobium Dreyfus et al. 1988 emend. Lang et al. 2013</synonym></term><term externalId="NCBI-6"><synonym uniqueName="ATCC 43989 &lt;type strain&gt;">ATCC 43989</synonym><synonym uniqueName="">Azorhizobium cau
View gist:3bf8e7fe1d13cd76fe8d8cc8b63afa07
Internal Exception
REST service call failed
com.wiley.gts.bce.common.remoting.client.BceRestTemplateResponseErrorHandler.handleError(BceRestTemplateResponseErrorHandler.java:53)
org.springframework.web.client.RestTemplate.handleResponse(RestTemplate.java:700)
org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:653)
org.springframework.web.client.RestTemplate.execute(RestTemplate.java:613)
org.springframework.web.client.RestTemplate.exchange(RestTemplate.java:559)
com.wiley.gts.bce.common.remoting.client.BceRestOperations.exchange(BceRestOperations.java:105)
com.wiley.gts.entity.service.controller.impl.v3.ProductV3ControllerImpl.getProducts(ProductV3ControllerImpl.java:267)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
View gist:15aeb0d9deeaf58f5d6735f1a50ba37c
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<exception>
<errorCode>1</errorCode>
<exceptionClass>com.temis.tsl.ApplicationException</exceptionClass>
<localizedMessage>com.temis.text.remote.essex.SimpleWebApplicationException: ESSEX returned the following error: Error while loading disambiguator extension (code 8)</localizedMessage>
<message>com.temis.text.remote.essex.SimpleWebApplicationException: ESSEX returned the following error: Error while loading disambiguator extension (code 8)</message>
<stackTraces>
script.tsl:592: com.temis.text.remote.essex.SimpleWebApplicationException: ESSEX returned the following error: Error while loading disambiguator extension (code 8)
at com.temis.tsl.ApplicationException.throwException(ApplicationException.java:24)
at com.temis.tsl.ReflectionHelper.invokeMethod(ReflectionHelper.java:323)