Mapping message info.

@param messageInfo the message info
@return the message info type
192896
private static MessageInfoType mapMessageInfo(MessageInfo messageInfo) {
        if (messageInfo == null) {
            return null;
        }
        MessageInfoType miType = new MessageInfoType();
        miType.setMessageId(messageInfo.getMessageId());
        miType.setFlowId(messageInfo.getFlowId());
        miType.setPorttype(convertString(messageInfo.getPortType()));
        miType.setOperationName(messageInfo.getOperationName());
        miType.setTransport(messageInfo.getTransportType());
        return miType;
    }
613956
public ClassInfo getClassInfo() {
        return new ClassInfo(version, access, name, signature, supername,
                             interfaces, methodMap, fieldMap);
    }
911233
public MessageProcessInfoModel getMessageProcessInfo()
    {
        if (this.getRecord(MessageProcessInfoModel.MESSAGE_PROCESS_INFO_FILE) == null)
            Record.makeRecordFromClassName(MessageProcessInfoModel.MESSAGE_PROCESS_INFO_FILE, this);
        return (MessageProcessInfoModel)this.getRecord(MessageProcessInfoModel.MESSAGE_PROCESS_INFO_FILE);
    }
848535
public List<CmsDetailPageInfo> getInfosForType(String type) {

        return new ArrayList<CmsDetailPageInfo>(m_map.get(type));
    }
749204
public MessageProcessInfoModel getMessageProcessInfo(String strMessageInfoType, String strContactType, String strRequestType, String strMessageProcessType, String strProcessType)
    {
        return null;    // No thin impl
    }
641716
@SuppressWarnings("unchecked")
	public static DataFormatConverter getConverterForTypeInfo(TypeInformation typeInfo) {
		DataFormatConverter converter = TYPE_INFO_TO_CONVERTER.get(typeInfo);
		if (converter != null) {
			return converter;
		}

		if (typeInfo instanceof BasicArrayTypeInfo) {
			BasicArrayTypeInfo arrayType = (BasicArrayTypeInfo) typeInfo;
			return new ObjectArrayConverter(arrayType.getTypeClass(), arrayType.getComponentInfo());
		} else if (typeInfo instanceof ObjectArrayTypeInfo) {
			ObjectArrayTypeInfo arrayType = (ObjectArrayTypeInfo) typeInfo;
			return new ObjectArrayConverter(arrayType.getTypeClass(), arrayType.getComponentInfo());
		} else if (typeInfo instanceof MapTypeInfo) {
			MapTypeInfo mapType = (MapTypeInfo) typeInfo;
			return new MapConverter(mapType.getKeyTypeInfo(), mapType.getValueTypeInfo());
		} else if (typeInfo instanceof RowTypeInfo) {
			return new RowConverter((RowTypeInfo) typeInfo);
		} else if (typeInfo instanceof PojoTypeInfo) {
			return new PojoConverter((PojoTypeInfo) typeInfo);
		} else if (typeInfo instanceof TupleTypeInfo) {
			return new TupleConverter((TupleTypeInfo) typeInfo);
		} else if (typeInfo instanceof TupleTypeInfoBase && Product.class.isAssignableFrom(typeInfo.getTypeClass())) {
			return new CaseClassConverter((TupleTypeInfoBase) typeInfo);
		} else if (typeInfo instanceof BinaryArrayTypeInfo) {
			return BinaryArrayConverter.INSTANCE;
		} else if (typeInfo instanceof BinaryMapTypeInfo) {
			return BinaryMapConverter.INSTANCE;
		} else if (typeInfo instanceof BaseRowTypeInfo) {
			return new BaseRowConverter(typeInfo.getArity());
		} else if (typeInfo.equals(BasicTypeInfo.BIG_DEC_TYPE_INFO)) {
			return new BaseRowConverter(typeInfo.getArity());
		} else if (typeInfo instanceof DecimalTypeInfo) {
			DecimalTypeInfo decimalType = (DecimalTypeInfo) typeInfo;
			return new DecimalConverter(decimalType.precision(), decimalType.scale());
		} else if (typeInfo instanceof BigDecimalTypeInfo) {
			BigDecimalTypeInfo decimalType = (BigDecimalTypeInfo) typeInfo;
			return new BigDecimalConverter(decimalType.precision(), decimalType.scale());
		} else if (typeInfo instanceof BinaryGenericTypeInfo) {
			return BinaryGenericConverter.INSTANCE;
		} else {
			return new GenericConverter(typeInfo.createSerializer(new ExecutionConfig()));
		}
	}
1053980
public void setMessagingType( String messagingType ) {

		// Properties are injected on every modification.
		// So, we just want to track changes.

		// We only want to reconfigure the messaging client
		// when the messaging type changes.
		if( ! Objects.equals( this.messagingType, messagingType )) {
			this.messagingType = messagingType;
			this.logger.fine( "Messaging type set to " + this.messagingType );

			// Explicitly require a reconfiguration.
			reconfigure();
		}
	}
654600
public void info( String msg, Throwable t )
    {
        if( m_delegate.isInfoEnabled() )
        {
            m_delegate.inform( msg, t );
        }
    }
416772
protected String getMessageType(final String message) {
    if (StringUtils.isBlank(defaultMessageType) || MESSAGE_TYPE_TEXT_VALUE
        .equalsIgnoreCase(defaultMessageType)
        || MESSAGE_TYPE_LONG_TEXT_VALUE.equalsIgnoreCase(defaultMessageType)) {
      return message.length() > getMaxLengthOfOneSms() ? MESSAGE_TYPE_LONG_TEXT_VALUE
          : MESSAGE_TYPE_TEXT_VALUE;
    }
    return defaultMessageType;
  }
1358006
public static Event map(EventType eventType) {
        Event event = new Event();
        event.setEventType(mapEventTypeEnum(eventType.getEventType()));
        Date date = (eventType.getTimestamp() == null)
                ? new Date() : eventType.getTimestamp().toGregorianCalendar().getTime();
        event.setTimestamp(date);
        event.setOriginator(mapOriginatorType(eventType.getOriginator()));
        MessageInfo messageInfo = mapMessageInfo(eventType.getMessageInfo());
        event.setMessageInfo(messageInfo);
        String content = mapContent(eventType.getContent());
        event.setContent(content);
        event.getCustomInfo().clear();
        event.getCustomInfo().putAll(mapCustomInfo(eventType.getCustomInfo()));
        return event;
    }
1307929
public String getMessageInfoType(BaseMessage externalMessage)
    {
        String strSubject = (String)externalMessage.getMessageHeader().get(EmailMessageTransport.SUBJECT_PARAM);
        if (strSubject != null)
            if (strSubject.toUpperCase().startsWith("RE:"))
                return MessageInfoTypeModel.REPLY;   // This is (most likely) a reply to my message.
        return super.getMessageInfoType(externalMessage);
    }
436298
public MessageInfo getMessageIn(MessageProcessInfo recMessageProcessInfo)
    {
        return (MessageInfo)((ReferenceField)recMessageProcessInfo.getField(MessageProcessInfo.MESSAGE_INFO_ID)).getReference();
    }
1134031
public void addMessage(String version, TDefinitions descriptionType, MessageInfo recMessageInfo)
    {
        TMessage messageType = wsdlFactory.createTMessage();
        descriptionType.getAnyTopLevelOptionalElement().add(messageType);
        String strMessageName = this.fixName(recMessageInfo.getField(MessageInfo.DESCRIPTION).toString());
        messageType.setName(strMessageName);
        TPart TPart = wsdlFactory.createTPart();        
        messageType.getPart().add(TPart);
        TPart.setName(strMessageName);
        String interfacens = this.getNamespace();
        String interfacename = this.fixName(recMessageInfo.getField(MessageInfo.CODE).toString());
        QName qname = new QName(interfacens, interfacename);
        TPart.setElement(qname);
    }
313970
public MessageProcessInfoModel getMessageProcessInfo(String strMessageKey)
    {
        int iOldKeyArea = this.getDefaultOrder();
        try {
            if (Utility.isNumeric(strMessageKey))
            {
                this.getField(MessageProcessInfo.ID).setString(strMessageKey);
                this.setKeyArea(MessageProcessInfo.ID_KEY);
                if (this.seek(null))
                    return this;
            }
            this.getField(MessageProcessInfo.CODE).setString(strMessageKey);
            this.setKeyArea(MessageProcessInfo.CODE_KEY);
            if (this.seek(null))
                return this;
            MessageInfo recMessageInfo = (MessageInfo)((ReferenceField)this.getField(MessageProcessInfo.MESSAGE_INFO_ID)).getReferenceRecord();
            recMessageInfo.addNew();
            recMessageInfo.getField(MessageInfo.CODE).setString(strMessageKey);
            recMessageInfo.setKeyArea(MessageInfo.CODE_KEY);
            if (recMessageInfo.seek(null))
            {
                if (MessageInfoType.REQUEST.equalsIgnoreCase(((ReferenceField)recMessageInfo.getField(MessageInfo.MESSAGE_INFO_TYPE_ID)).getReference().getField(MessageInfoType.CODE).toString()))
                {   // Must be a request!
                    this.getField(MessageProcessInfo.MESSAGE_INFO_ID).moveFieldToThis(recMessageInfo.getField(MessageInfo.ID));
                    this.getField(MessageProcessInfo.MESSAGE_TYPE_ID).setValue(((ReferenceField)this.getField(MessageProcessInfo.MESSAGE_TYPE_ID)).getIDFromCode(MessageType.MESSAGE_IN));
                    this.getField(MessageProcessInfo.PROCESS_TYPE_ID).setValue(((ReferenceField)this.getField(MessageProcessInfo.PROCESS_TYPE_ID)).getIDFromCode(ProcessType.INFO));
                    this.setKeyArea(MessageProcessInfo.MESSAGE_INFO_ID_KEY);
                    if (this.seek(null))
                        return this;
                    this.getField(MessageProcessInfo.PROCESS_TYPE_ID).setValue(((ReferenceField)this.getField(MessageProcessInfo.PROCESS_TYPE_ID)).getIDFromCode(ProcessType.UPDATE));    // Should not be, but check anyway
                    if (this.seek(null))
                        return this;
                }
            }
        } catch (DBException ex)    {
            ex.printStackTrace();
        } finally {
            this.setKeyArea(iOldKeyArea);   // Set this back
        }
        return null;
    }
945397
private String getMessageType(FacesMessage message) {
		if (message.getSeverity().equals(FacesMessage.SEVERITY_WARN))
			return "warning";
		else if (message.getSeverity().equals(FacesMessage.SEVERITY_ERROR))
			return "danger";
		else if (message.getSeverity().equals(FacesMessage.SEVERITY_FATAL))
			return "danger";
		else if (message.getSeverity().equals(FacesMessage.SEVERITY_INFO))
			return "info";
		return "success";
	}
468862
protected static AVIMMessage parseTypedMessage(AVIMMessage message) {
    int messageType = getMessageType(message.getContent());
    if (messageType != 0) {
      Class<? extends AVIMTypedMessage> clazz = messageTypesRepository.get(messageType);
      if (clazz != null) {
        try {
          AVIMMessage typedMessage = clazz.newInstance();
          typedMessage.setConversationId(message.getConversationId());
          typedMessage.setFrom(message.getFrom());
          typedMessage.setDeliveredAt(message.getDeliveredAt());
          typedMessage.setTimestamp(message.getTimestamp());
          typedMessage.setContent(message.getContent());
          typedMessage.setMessageId(message.getMessageId());
          typedMessage.setMessageStatus(message.getMessageStatus());
          typedMessage.setMessageIOType(message.getMessageIOType());
          typedMessage.uniqueToken = message.uniqueToken;
          typedMessage.currentClient = message.currentClient;
          typedMessage.mentionAll = message.mentionAll;
          typedMessage.mentionList = message.mentionList;
          message = typedMessage;
        } catch (Exception e) {
        }
      }
    }
    return message;
  }
829782
private MessageType getMessageType(Message response) {
        String messageTypeString = (String) response.getHeader(MessageHeaders.MESSAGE_TYPE);
        if (MessageType.knows(messageTypeString)){
            return MessageType.valueOf(messageTypeString.toUpperCase());
        }
        return null;
    }