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
@Converter | |
public class GenderConverter implements AttributeConverter<Gender, String> { | |
@Override | |
public String convertToDatabaseColumn(Gender gender) { | |
return gender.getCode(); | |
} | |
@Override | |
public Gender convertToEntityAttribute(String code) { |
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
public enum Gender { | |
FEMALE("F"), | |
MALE("M"), | |
NOT_AVAILABLE("N"); | |
private final String code; | |
Gender(String code) { | |
this.code = code; |
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
@Entity | |
public class Person { | |
@Id | |
private Long id; | |
private String firstName; | |
private String lastName; | |
@Convert(converter = GenderConverter.class) | |
private Gender gender; |
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
@Converter | |
public class GenderConverter implements AttributeConverter<Gender, String> { | |
@Override | |
public String convertToDatabaseColumn(Gender gender) { | |
return gender.getCode(); | |
} | |
@Override | |
public Gender convertToEntityAttribute(String code) { |
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
package br.com.fredericci.test; | |
import java.util.Date; | |
import com.tibco.tibrv.Tibrv; | |
import com.tibco.tibrv.TibrvException; | |
import com.tibco.tibrv.TibrvListener; | |
import com.tibco.tibrv.TibrvMsg; | |
import com.tibco.tibrv.TibrvMsgCallback; | |
import com.tibco.tibrv.TibrvRvdTransport; |
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
/* | |
* Translated default messages for the jQuery validation plugin. | |
* Locale: PT_BR | |
*/ | |
jQuery.extend(jQuery.validator.messages, { | |
required: "Campo obrigatório!", | |
remote: "Por favor, corrija este campo.", | |
email: "Por favor, forneça um endereço eletrônico válido.", | |
url: "Por favor, forneça uma URL válida.", | |
date: "Por favor, forneça uma data válida.", |
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
//searchText is a input type text | |
$('#searchText').bind('keyup', function() { | |
var searchString = $(this).val(); | |
$("ul li").each(function(index, value) { | |
currentName = $(value).text() | |
if( currentName.toUpperCase().indexOf(searchString.toUpperCase()) > -1) { |
OlderNewer