LC_ALL=de_DE@Euro
LC_MESSAGES=de_DE@Euro
LC_CTYPE=de_DE@Euro
Language Settings
private static List<Tuple<Short, Short>> leseEingabe(DriverManagerDataSource ds)
throws ZFileException, UnsupportedEncodingException
{
SimpleJdbcTemplate simpleJdbcTemplate = new SimpleJdbcTemplate(
ds);
List<Tuple<Short, Short>> l = simpleJdbcTemplate.query(“SELECT AKTUELLE_GST, AKTUELLE_MANR FROM AVIS.BEST_UEBERTR_TB”,
new ParameterizedRowMapper<Tuple<Short, Short>>() {
public Tuple<Short, Short> mapRow(ResultSet rs, int arg1)
throws SQLException {
Tuple<Short,Short> t = new Tuple<Short, Short>(((Integer)rs.getObject(1)).shortValue(), ((Integer)rs.getObject(2)).shortValue());
// Extract row to user object
return t;
}
});
return l;
}
ByteArrayInputStream bis = new ByteArrayInputStream(myAntragRequest.getEAntragDataFile().getFileContent());
SAXParserFactory fabrik = SAXParserFactory.newInstance();
de.vb.dms.webservices.parser.ParserHandler myHandler;
try
{
fabrik.setValidating(true);
SAXParser parser = fabrik.newSAXParser();
XMLReader reader = parser.getXMLReader();
myHandler = new de.vb.dms.webservices.parser.ParserHandler();
reader.setContentHandler(myHandler);
reader.parse(new InputSource(bis));
}
catch (Exception e)
{
logger.error(“Fehler beim Parsen : ” + e + e.getMessage());
}
myInfo.setAntragsteller(de.vb.dms.webservices.parser.ParserHandler.nameVorname);
Any ideas how to shorten this?
import javax.annotation.Resource;
import javax.jws.WebService;
import javax.servlet.ServletContext;
import javax.xml.ws.WebServiceContext;
import javax.xml.ws.handler.MessageContext;
import org.springframework.web.context.WebApplicationContext;
import org.springframework.web.context.support.WebApplicationContextUtils;
@WebService
public class MyWebService {
// boilerplate code begins
@Resource
private WebServiceContext context;
private WebApplicationContext webApplicationContext = null;
/**
* @return
* @throws IllegalStateException
*/
private WebApplicationContext getWebApplicationContext()
throws IllegalStateException {
if (webApplicationContext != null)
return webApplicationContext;
ServletContext servletContext =
(ServletContext) context.getMessageContext().get(
MessageContext.SERVLET_CONTEXT);
webApplicationContext =
WebApplicationContextUtils.getRequiredWebApplicationContext(servletContext);
return webApplicationContext;
}
}
\documentclass[11pt,a4paper]{moderncv}
\moderncvtheme[blue]{casual}
\usepackage[latin1]{inputenc}
\usepackage[scale=0.8]{geometry}
\AtBeginDocument{\recomputelengths}
\AtBeginDocument{\definecolor{sectionrectanglecolor}{rgb}{0,0,0}}
\AtBeginDocument{\definecolor{sectiontitlecolor}{rgb}{1,0,0}}
\makeatletter
\renewcommand{\section}[1]
{ \vspace*{2.5ex \@plus 1ex \@minus .2ex}%
\phantomsection{}% reset the anchor for hyperrefs
\addcontentsline{toc}{part}{#1}%
\parbox[m]{\hintscolumnwidth}{\raggedleft \hintfont{\color{sectionrectanglecolor}\rule{\hintscolumnwidth}{1pt}}}%<- auf 11pt geaendert
\hspace{\separatorcolumnwidth}%
\parbox[m]{\maincolumnwidth}{\sectionstyle{#1}}\\[1ex]}
\makeatother
\firstname{John}
\familyname{Doe}
\address{Street 1}{11111 XYZ}
\phone{012345}
\email{mail@mail.de}
\begin{document}
\maketitle
\section{Testbalken}
\cvline{Name}{\small Ich Du Er Sie Es}
\end{document}
\documentclass{article} % (Präamble)
\usepackage{color}
\definecolor{mygray}{gray}{.75}
\newcommand{\varname}{Var-Inhalt}
\begin{document}
\color{black}Hallo \varname
\end{document}
%\renewcommand{\familydefault}{\sfdefault} %andere Schriftart, Helvetica Serifenlos
%\usepackage{helvet}
An example for a colored line in latex
\documentclass{article} % (Präamble)
\usepackage{color}
\definecolor{mygray}{gray}{.75}
\begin{document}
\color{mygray}\line(0,1){500}
\end{document}
Currently I ran into the problem how to get the date from a <mx:Datechooser> where the mouse is over. Obviously there is no direct possibility to get it from the datechooser component. I googled quite days around and finally I found a solution for this.
The idea is to generate mouseover events from the datechooser. Normally it’s only fired once on entering the component. So how to generate multiple events everytime the position changes in the component?
It’s done with an invisible button. The button has two states:
- visible=false
- visible=true but due to fillAlphas=”[0.0, 0.0, 0.0, 0.0]” cornerRadius=”0″ alpha=”0.0″ still invisible for the customer
Each time the button gets visible=true it automatically fires a button mouseover event. We use this event to set the visibility again to false. What happens right now? You’re right
The <mx:Datechooser> fires a new mouseover event with the current position of the selected date. It’s kind of brainfuck but right now it’s the only possibility to realize it I know. If you have a better solution, please tell me.
Note the button has the same size like the datechooser to cover all of its area.
Another approach the change the invisible buttons visibility (isn’t that curious?) is a timer event. This is also realized in the code:
<?xml version=”1.0″ encoding=”utf-8″?>
<mx:Application xmlns:mx=”http://www.adobe.com/2006/mxml” layout=”absolute” themeColor=”#0EFF02″
creationComplete=”init()”>
<mx:Script>
<![CDATA[
import mx.core.UITextField;
import mx.controls.Alert;
[Bindable]private var day:Date;
public var myTimer:Timer
private function init():void {
myTimer= new Timer(1000);
myTimer.addEventListener(“timer”, timerHandler);
}
private function useDate2(event:MouseEvent):void {
if(event.target is UITextField )
{
if(Number(event.target.text)>0&&Number(event.target.text)<31)
sel.text+=event.target.text+”-”+(myDatechooser.displayedMonth+1)+”-”+myDatechooser.displayedYear+”\n”;
}
myTimer.start();
}
public function dateChooserMouseOut(event:MouseEvent):void {
setButtonInvisible();
myTimer.stop();
}
public function timerHandler(event:TimerEvent):void {
toggleButtonVisibility();
}
private function initDatechooser():void {
var aktDate:Date = new Date();
myDatechooser.selectedDate=aktDate;
}
private function setButtonInvisible():void{
invBTN.visible=false;
}
private function toggleButtonVisibility():void{
invBTN.visible=!invBTN.visible;
}
]]>
</mx:Script>
<mx:DateChooser id=”myDatechooser” x=”114″ y=”24″
mouseOver=”useDate2(event)” mouseOut=”dateChooserMouseOut(event)”
backgroundColor=”#FFFFFF” creationComplete=”initDatechooser()” />
<mx:TextArea id=”sel” height=”447″ width=”206″ x=”104″ y=”212″ valueCommit=”sel.verticalScrollPosition=sel.maxVerticalScrollPosition”/>
<mx:Button x=”114″ y=”24″ id=”invBTN” label=”Button” visible=”false” width=”174″ height=”180″ mouseOut=”setButtonInvisible()” mouseOver=”setButtonInvisible()”/>
</mx:Application>
0&&Number(event.target.text)