CurtHagenlocher commented on code in PR #39871: URL: https://github.com/apache/arrow/pull/39871#discussion_r1479190568
########## csharp/test/Apache.Arrow.Compression.Tests/ArrowFileWriterTests.cs: ########## @@ -0,0 +1,147 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System; +using System.Collections.Generic; +using Apache.Arrow.Ipc; +using System.IO; +using System.Threading.Tasks; +using Apache.Arrow.Tests; +using K4os.Compression.LZ4; +using Xunit; Review Comment: nit: sort ########## csharp/test/Apache.Arrow.Compression.Tests/ArrowStreamWriterTests.cs: ########## @@ -0,0 +1,184 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System; +using System.Collections.Generic; +using Apache.Arrow.Ipc; +using System.IO; +using System.Threading.Tasks; +using Apache.Arrow.Tests; +using K4os.Compression.LZ4; +using Xunit; Review Comment: nit: sort ########## csharp/src/Apache.Arrow/Ipc/IpcOptions.cs: ########## @@ -25,6 +25,23 @@ public class IpcOptions /// </summary> public bool WriteLegacyIpcFormat { get; set; } + /// <summary> + /// The compression codec to use to compress data buffers. + /// If null (the default value), no compression is used. + /// </summary> + public CompressionCodecType? CompressionCodec { get; set; } + + /// <summary> + /// The compression codec factory used to create compression codecs. + /// Must be provided if a CompressionCodec is specified. + /// </summary> + public ICompressionCodecFactory CompressionCodecFactory { get; set; } Review Comment: Another approach might be to take an ICompressionCodec instead; that seems a bit more options-like than taking both the factory and the codec identity. This would probably require ICompressionCodec to expose a CompressionCodecType property, though. I don't know that I feel strongly either way. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
