Rev

Rev 1822 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | Bug Tracker

Rev 1822 Rev 2655
Line 2... Line 2...
2
 * @author      ETSI / STF481 / Yann Garcia
2
 * @author      ETSI / STF481 / Yann Garcia
3
 * @version     $URL: file:///D:/RepositoriesNew/ITS/trunk/javasrc/codec/org/etsi/ttcn/codec/its/security/GeographicRegion.java $
3
 * @version     $URL: file:///D:/RepositoriesNew/ITS/trunk/javasrc/codec/org/etsi/ttcn/codec/its/security/GeographicRegion.java $
4
 *              $Id: GeographicRegion.java 1789 2014-11-04 13:09:48Z garciay $
4
 *              $Id: GeographicRegion.java 2655 2017-01-26 10:46:08Z filatov $
5
 */
5
 */
6
package org.etsi.ttcn.codec.its.security;
6
package org.etsi.ttcn.codec.its.security;
7
7
8
import org.etsi.ttcn.codec.CodecBuffer;
8
import org.etsi.ttcn.codec.CodecBuffer;
9
import org.etsi.ttcn.codec.MainCodec;
9
import org.etsi.ttcn.codec.MainCodec;
Line 39... Line 39...
39
     * @desc Set the variant according to the GeographicRegion type
39
     * @desc Set the variant according to the GeographicRegion type
40
     * @see See Draft ETSI TS 103 097 V1.1.14 Clause 5.7    TrailerFieldType
40
     * @see See Draft ETSI TS 103 097 V1.1.14 Clause 5.7    TrailerFieldType
41
     */
41
     */
42
    @Override
42
    @Override
43
    protected void preDecodeField(String fieldName, CodecBuffer buf, Type decodingHypothesis, RecordValue rv) {
43
    protected void preDecodeField(String fieldName, CodecBuffer buf, Type decodingHypothesis, RecordValue rv) {
44
//        System.out.println(">>> GeographicRegion.preDecodeField: " + fieldName + ", " + decodingHypothesis.getName() + ", " + rv.getType().getName());
44
//        TERFactory.getInstance().logDebug(">>> GeographicRegion.preDecodeField: " + fieldName + ", " + decodingHypothesis.getName() + ", " + rv.getType().getName());
45
        if (fieldName.equals("region_type")) {
45
        if (fieldName.equals("region_type")) {
46
            byte type_ = buf.getBytes(0, 1)[0];
46
            byte type_ = buf.getBytes(0, 1)[0];
47
            mainCodec.setPresenceHint("region", true);
47
            mainCodec.setPresenceHint("region", true);
48
            switch (type_) {
48
            switch (type_) {
49
                case (byte)c_circle:
49
                case (byte)c_circle: