22 * SysML v2 REST/HTTP Pilot Implementation
33 * Copyright (C) 2020 InterCAX LLC
44 * Copyright (C) 2020 California Institute of Technology ("Caltech")
5- * Copyright (C) 2021 Twingineer LLC
5+ * Copyright (C) 2021-2022 Twingineer LLC
66 *
77 * This program is free software: you can redistribute it and/or modify
88 * it under the terms of the GNU Lesser General Public License as published by
2222
2323package org .omg .sysml .lifecycle .impl ;
2424
25+ import com .fasterxml .jackson .annotation .JsonGetter ;
2526import com .fasterxml .jackson .annotation .JsonProperty ;
27+ import com .fasterxml .jackson .annotation .JsonSetter ;
2628import com .fasterxml .jackson .annotation .JsonView ;
2729import com .fasterxml .jackson .databind .annotation .JsonDeserialize ;
2830import com .fasterxml .jackson .databind .annotation .JsonSerialize ;
@@ -42,6 +44,7 @@ public class CommitImpl extends RecordImpl implements Commit {
4244 private Project owningProject ;
4345 private Set <DataVersion > change ;
4446 private ZonedDateTime created ;
47+ private String description ;
4548 private Commit previousCommit ;
4649
4750 @ Override
@@ -82,6 +85,21 @@ public void setCreated(ZonedDateTime created) {
8285 this .created = created ;
8386 }
8487
88+ @ JsonProperty (required = true )
89+ @ JsonGetter
90+ @ Lob
91+ @ org .hibernate .annotations .Type (type = "org.hibernate.type.TextType" )
92+ @ javax .persistence .Column (name = "description" , table = "Commit" )
93+ public String getDescription () {
94+ return description ;
95+ }
96+
97+ @ JsonProperty (required = true )
98+ @ JsonSetter
99+ public void setDescription (String description ) {
100+ this .description = description ;
101+ }
102+
85103 @ ManyToOne (targetEntity = CommitImpl .class , fetch = FetchType .LAZY )
86104 @ JsonSerialize (as = CommitImpl .class , using = RecordSerialization .RecordSerializer .class )
87105 @ JsonView (Views .Compact .class )
0 commit comments