<commit_before>package com.sora.util.akatsuki.parceler;

import com.sora.util.akatsuki.TransformationTemplate;
import com.sora.util.akatsuki.TransformationTemplate.StatementTemplate;
import com.sora.util.akatsuki.TransformationTemplate.StatementTemplate.Type;
import com.sora.util.akatsuki.TypeConstraint;
import com.sora.util.akatsuki.TypeConstraint.Bound;
import com.sora.util.akatsuki.TypeFilter;

import org.parceler.Parcel;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * Add {@code @IncludeClasses(ParcelerSupport.class) } to any class to enable
 */
//@formatter:off
@SuppressWarnings("unused")
@TransformationTemplate(
		save = @StatementTemplate("{{bundle}}.putParcelable({{keyName}}, org.parceler.Parcels.wrap(" +
				                          "com.sora.util.akatsuki.parceler.ParcelerSupport.resolveInterfaceClass(" +
				                          "{{fieldName}}), {{fieldName}}))"),
		restore = @StatementTemplate(type = Type.ASSIGNMENT,
				                     value = "org.parceler.Parcels.unwrap({{bundle}}.getParcelable({{keyName}}))",
				                     variable = "{{fieldName}}"),
		filters = {@TypeFilter(type = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = List.class, bound = Bound.EXTENDS),
						       parameters = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = Set.class, bound = Bound.EXTENDS),
				               parameters = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = Map.class, bound = Bound.EXTENDS),
				               parameters = @TypeConstraint(type = Parcel.class))
		          }
		)
//@formatter:on
public class ParcelerSupport {
<commit_msg>Adding support for null values<commit_after>package com.sora.util.akatsuki.parceler;

import com.sora.util.akatsuki.TransformationTemplate;
import com.sora.util.akatsuki.TransformationTemplate.StatementTemplate;
import com.sora.util.akatsuki.TransformationTemplate.StatementTemplate.Type;
import com.sora.util.akatsuki.TypeConstraint;
import com.sora.util.akatsuki.TypeConstraint.Bound;
import com.sora.util.akatsuki.TypeFilter;

import org.parceler.Parcel;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * Add {@code @IncludeClasses(ParcelerSupport.class) } to any class to enable
 */
//@formatter:off
@SuppressWarnings("unused")
@TransformationTemplate(
		save = @StatementTemplate("{{bundle}}.putParcelable({{keyName}} == null?null:{{keyName}}, org.parceler.Parcels.wrap(" +
				                          "com.sora.util.akatsuki.parceler.ParcelerSupport.resolveInterfaceClass(" +
				                          "{{fieldName}}), {{fieldName}}))"),
		restore = @StatementTemplate(type = Type.ASSIGNMENT,
				                     value = "org.parceler.Parcels.unwrap({{bundle}}.getParcelable({{keyName}}))",
				                     variable = "{{fieldName}}"),
		filters = {@TypeFilter(type = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = List.class, bound = Bound.EXTENDS),
						       parameters = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = Set.class, bound = Bound.EXTENDS),
				               parameters = @TypeConstraint(type = Parcel.class)),
				   @TypeFilter(type = @TypeConstraint(type = Map.class, bound = Bound.EXTENDS),
				               parameters = @TypeConstraint(type = Parcel.class))
		          }
		)
//@formatter:on
public class ParcelerSupport {

{'fraction_non_alphanumeric': 0.1373439273552781, 'fraction_numerical': 0.0, 'mean_word_length': 3.4790343074968235, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2657613', 'n_tokens_mistral': 1161, 'n_tokens_neox': 1053, 'n_words': 161}